1
0
Pārlūkot izejas kodu

kernel: Directly export updateMethod.

Herbert Vojčík 7 gadi atpakaļ
vecāks
revīzija
3826db99f6
1 mainītis faili ar 2 papildinājumiem un 4 dzēšanām
  1. 2 4
      support/kernel-fundamentals.js

+ 2 - 4
support/kernel-fundamentals.js

@@ -246,7 +246,7 @@ define(['./compatibility' /* TODO remove */], function () {
             traitOrBehavior.methods = Object.create(null);
         };
 
-        function updateMethod (selector, traitOrBehavior) {
+        this.updateMethod = function (selector, traitOrBehavior) {
             var oldMethod = traitOrBehavior.methods[selector],
                 newMethod = traitOrBehavior.localMethods[selector];
             if (oldMethod == null && newMethod == null) {
@@ -262,9 +262,7 @@ define(['./compatibility' /* TODO remove */], function () {
                 traitOrBehavior.methodRemoved(oldMethod);
             }
             if (st._methodReplaced) st._methodReplaced(newMethod, oldMethod, traitOrBehavior);
-        }
-
-        this.updateMethod = updateMethod;
+        };
     }
 
     function ArraySetBrik (brikz, st) {