Replace deprecated String.prototype.substr()

String.prototype.substr() is deprecated (see https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/substr) so we replace it with slice() or substring() which work similarily but aren't deprecated.
Signed-off-by: Tobias Speicher <rootcommander@gmail.com>
This commit is contained in:
Tobias Speicher 2022-02-20 15:09:12 +01:00
parent 2523498a37
commit 8edfddc409
No known key found for this signature in database
GPG key ID: 2CF824BD810C3BDB
4 changed files with 4 additions and 4 deletions

View file

@ -695,7 +695,7 @@ export class BrowserWindow {
let latestbranchjson = await latestbranch.json()
let base_url = latestbranchjson[0].url
base_url = base_url.substr(0, base_url.lastIndexOf('/'))
base_url = base_url.substring(0, base_url.lastIndexOf('/'))
const options: any = {
provider: 'generic',