groovy-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pa...@apache.org
Subject [1/2] groovy git commit: formatting
Date Sun, 01 Apr 2018 13:41:37 GMT
Repository: groovy
Updated Branches:
  refs/heads/GROOVY_2_6_X a259ad3b1 -> cf6a6c7c5


formatting


Project: http://git-wip-us.apache.org/repos/asf/groovy/repo
Commit: http://git-wip-us.apache.org/repos/asf/groovy/commit/5748573b
Tree: http://git-wip-us.apache.org/repos/asf/groovy/tree/5748573b
Diff: http://git-wip-us.apache.org/repos/asf/groovy/diff/5748573b

Branch: refs/heads/GROOVY_2_6_X
Commit: 5748573b2dafd9664e5e79a0aeab0ea43d7628e6
Parents: a259ad3
Author: Paul King <paulk@asert.com.au>
Authored: Sun Apr 1 23:09:29 2018 +1000
Committer: Paul King <paulk@asert.com.au>
Committed: Sun Apr 1 23:41:19 2018 +1000

----------------------------------------------------------------------
 .../runtime/metaclass/MetaClassRegistryImpl.java  | 18 +++++++++---------
 1 file changed, 9 insertions(+), 9 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/groovy/blob/5748573b/src/main/java/org/codehaus/groovy/runtime/metaclass/MetaClassRegistryImpl.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/codehaus/groovy/runtime/metaclass/MetaClassRegistryImpl.java
b/src/main/java/org/codehaus/groovy/runtime/metaclass/MetaClassRegistryImpl.java
index ff30a2b..2914d02 100644
--- a/src/main/java/org/codehaus/groovy/runtime/metaclass/MetaClassRegistryImpl.java
+++ b/src/main/java/org/codehaus/groovy/runtime/metaclass/MetaClassRegistryImpl.java
@@ -513,22 +513,22 @@ public class MetaClassRegistryImpl implements MetaClassRegistry{
 
         public void onModule(final ExtensionModule module) {
             if (moduleRegistry.hasModule(module.getName())) {
-            ExtensionModule loadedModule = moduleRegistry.getModule(module.getName());
-            if (loadedModule.getVersion().equals(module.getVersion())) {
-                // already registered
-                return;
-            } else {
-                throw new GroovyRuntimeException("Conflicting module versions. Module ["+module.getName()+"
is loaded in version "+
-                        loadedModule.getVersion()+" and you are trying to load version "+module.getVersion());
+                ExtensionModule loadedModule = moduleRegistry.getModule(module.getName());
+                if (loadedModule.getVersion().equals(module.getVersion())) {
+                    // already registered
+                    return;
+                } else {
+                    throw new GroovyRuntimeException("Conflicting module versions. Module
[" + module.getName() + " is loaded in version " +
+                            loadedModule.getVersion() + " and you are trying to load version
" + module.getVersion());
+                }
             }
-        }
             moduleRegistry.addModule(module);
             // register MetaMethods
             List<MetaMethod> metaMethods = module.getMetaMethods();
             for (MetaMethod metaMethod : metaMethods) {
                 CachedClass cachedClass = metaMethod.getDeclaringClass();
                 List<MetaMethod> methods = map.get(cachedClass);
-                if (methods==null) {
+                if (methods == null) {
                     methods = new ArrayList<MetaMethod>(4);
                     map.put(cachedClass, methods);
                 }


Mime
View raw message