Chore: Replace deprecated String.prototype.substr() (#46763)
.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:
@@ -8,7 +8,7 @@ import { AxiosResponse } from 'axios';
|
||||
|
||||
const resolveContentType = (extension: string): string => {
|
||||
if (extension.startsWith('.')) {
|
||||
extension = extension.substr(1);
|
||||
extension = extension.slice(1);
|
||||
}
|
||||
switch (extension) {
|
||||
case 'zip':
|
||||
|
||||
Reference in New Issue
Block a user