refactor: replace deprecated String.prototype.substr()

.substr() is deprecated so we replace it with .slice() which works similarily but isn't deprecated

Signed-off-by: Tobias Speicher <rootcommander@gmail.com>
This commit is contained in:
Tobias Speicher committed 2022-03-22 10:02:41 +01:00
1 parent de277c88c7
commit 522189ec36
1 file changed
+1 -1
+1 -1
View File
@@ -241,7 +241,7 @@
// Loop results
$.each(schemasCount, function(schema, hits){
// IF TEST CONTINUE
if(schema.substr(schema.length - 4) == 'test')
if(schema.slice(-4) == 'test')
return;
var slug = makeSlug(schema);