mirror of
https://iceshrimp.dev/crimekillz/iceshrimp-161sh.git
synced 2024-11-22 20:23:49 +01:00
Fix #4063
This commit is contained in:
parent
c1f2565cb0
commit
07fe2f1401
@ -5,16 +5,6 @@ import ProgressDialog from '../views/components/progress-dialog.vue';
|
||||
export default ($root: any) => {
|
||||
|
||||
const cropImage = file => new Promise((resolve, reject) => {
|
||||
|
||||
const regex = RegExp('\.(jpg|jpeg|png|gif|webp|bmp|tiff)$');
|
||||
if (!regex.test(file.name) ) {
|
||||
$root.dialog({
|
||||
title: locale['desktop']['invalid-filetype'],
|
||||
text: null
|
||||
});
|
||||
return reject('invalid-filetype');
|
||||
}
|
||||
|
||||
const w = $root.new(CropWindow, {
|
||||
image: file,
|
||||
title: locale['desktop']['avatar-crop-title'],
|
||||
|
@ -5,16 +5,6 @@ import ProgressDialog from '../views/components/progress-dialog.vue';
|
||||
export default ($root: any) => {
|
||||
|
||||
const cropImage = file => new Promise((resolve, reject) => {
|
||||
|
||||
const regex = RegExp('\.(jpg|jpeg|png|gif|webp|bmp|tiff)$');
|
||||
if (!regex.test(file.name) ) {
|
||||
$root.dialog({
|
||||
title: locale['desktop']['invalid-filetype'],
|
||||
text: null
|
||||
});
|
||||
return reject('invalid-filetype');
|
||||
}
|
||||
|
||||
const w = $root.new(CropWindow, {
|
||||
image: file,
|
||||
title: locale['desktop']['banner-crop-title'],
|
||||
|
Loading…
Reference in New Issue
Block a user