From 83e9aefff52d4572bfc48a2c2d83f0776d32234a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Julio=20C=C3=A9sar?= Date: Mon, 11 Jun 2018 00:48:24 +0200 Subject: [PATCH] CB-14125:(android) Increase old plugin compatibility --- bin/templates/cordova/lib/pluginHandlers.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/templates/cordova/lib/pluginHandlers.js b/bin/templates/cordova/lib/pluginHandlers.js index f57c2837..e6d7ffdf 100644 --- a/bin/templates/cordova/lib/pluginHandlers.js +++ b/bin/templates/cordova/lib/pluginHandlers.js @@ -320,8 +320,8 @@ function studioPathRemap (obj) { if (!obj.targetDir.includes('app/src/main')) { if (obj.src.endsWith('.java')) { return path.join('app/src/main/java', obj.targetDir.substring(4), path.basename(obj.src)); - } else if (obj.src.endsWith('.xml')) { - // We are making a huge assumption here that XML files will be going to res/xml or values/xml + } else { + // For all other files, add 'app/src/main' to the targetDir if it didn't have it already return path.join('app/src/main', obj.targetDir, path.basename(obj.src)); } }