mirror of
https://github.com/apache/cordova-android.git
synced 2025-02-22 00:32:55 +08:00
Merge pull request #449 from jcesarmobile/CB-14125
CB-14125:(android) Increase old plugin compatibility
This commit is contained in:
commit
472ab626d6
4
bin/templates/cordova/lib/pluginHandlers.js
vendored
4
bin/templates/cordova/lib/pluginHandlers.js
vendored
@ -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));
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user