Merge "Fix destination branch to resolve OWNERS file"
diff --git a/owners-common/BUCK b/owners-common/BUCK
deleted file mode 100644
index d5a5b3b..0000000
--- a/owners-common/BUCK
+++ /dev/null
@@ -1,53 +0,0 @@
-include_defs('//bucklets/gerrit_plugin.bucklet')
-include_defs('//plugins/owners-common/common.defs')
-include_defs('//lib/maven.defs')
-include_defs('//lib/prolog/prolog.defs')
-
-JACKSON_REV = '2.1.1'
-maven_jar(
-  name = 'jackson-core',
-  id = 'com.fasterxml.jackson.core:jackson-core:%s' % JACKSON_REV,
-  license = 'Apache2.0',
-)
-
-maven_jar(
-  name = 'jackson-databind',
-  id = 'com.fasterxml.jackson.core:jackson-databind:%s' % JACKSON_REV,
-  license = 'Apache2.0',
-)
-
-maven_jar(
-  name = 'jackson-annotations',
-  id = 'com.fasterxml.jackson.core:jackson-annotations:%s' % JACKSON_REV,
-  license = 'Apache2.0',
-)
-
-maven_jar(
-  name = 'jackson-dataformat-yaml',
-  id = 'com.fasterxml.jackson.dataformat:jackson-dataformat-yaml:%s' % JACKSON_REV,
-  license = 'Apache2.0',
-)
-
-# see common.defs on why this is a java_library2 rather than java_library
-java_library(
-  name = 'common',
-  srcs = glob([
-    'src/main/java/**/*.java',
-  ]),
-  provided_deps = GERRIT_PLUGIN_API + EXTERNAL_DEPS,
-  visibility = ['PUBLIC'],
-)
-
-# Needed ONLY to allow the project import into Eclipse
-gerrit_plugin(
-  name = 'owners-common',
-  srcs = glob([
-    'src/main/java/**/*.java',
-  ]),
-  manifest_entries = [
-    'Implementation-Title: Gerrit OWNERS common library',
-    'Implementation-URL: https://gerrit.googlesource.com/plugins/owners',
-    'Gerrit-PluginName: owners-common',
-  ],
-  deps = EXTERNAL_DEPS,
-)
diff --git a/owners-common/BUILD b/owners-common/BUILD
index 3711359..0e2355f 100644
--- a/owners-common/BUILD
+++ b/owners-common/BUILD
@@ -3,7 +3,6 @@
 load("//tools/bzl:plugin.bzl", "gerrit_plugin", "PLUGIN_DEPS", "PLUGIN_TEST_DEPS")
 load("//plugins/owners-common:common.bzl", "EXTERNAL_DEPS")
 
-# see common.defs on why this is a java_library2 rather than java_library
 java_library(
     name = "owners-common",
     srcs = glob([
diff --git a/owners-common/src/main/java/com/vmware/gerrit/owners/common/AccountsImpl.java b/owners-common/src/main/java/com/vmware/gerrit/owners/common/AccountsImpl.java
index a5d3399..ec6df7f 100644
--- a/owners-common/src/main/java/com/vmware/gerrit/owners/common/AccountsImpl.java
+++ b/owners-common/src/main/java/com/vmware/gerrit/owners/common/AccountsImpl.java
@@ -142,6 +142,6 @@
   }
 
   private String getSchemeRest(String scheme, String key) {
-    return null != scheme ? key.substring(scheme.length() + 1) : null;
+    return null != scheme ? key.substring(scheme.length() + 1) : key;
   }
 }