Skip to content
This repository was archived by the owner on Feb 28, 2022. It is now read-only.

Commit 857a6a4

Browse files
committed
fix(tests): String.prototype.startswith is ES6 only and phantomjs do not have it
1 parent 5e75d38 commit 857a6a4

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/api/api.service.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -159,8 +159,8 @@ function osmAPI($base64, $http, $q, osmSettingsService, osmUtilsService, options
159159
if (!d) {
160160
return d;
161161
}
162-
if (d.startsWith) {
163-
if (d.startsWith('<?xml')) {
162+
if (d.substr) {
163+
if (d.substr(0, 5) === '<?xml') {
164164
return osmUtilsService.xml2js(d);
165165
}
166166
} else if (isElement(d)) {

0 commit comments

Comments
 (0)