mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-22 23:00:56 +01:00
fix not working file upload, if not mime-type specified
This commit is contained in:
parent
1a91dfab7d
commit
25615d7ee0
@ -281,6 +281,8 @@ var et2_file = /** @class */ (function (_super) {
|
|||||||
* @return boolean
|
* @return boolean
|
||||||
*/
|
*/
|
||||||
et2_file.prototype.checkMime = function (f) {
|
et2_file.prototype.checkMime = function (f) {
|
||||||
|
if (!this.options.mime)
|
||||||
|
return true;
|
||||||
var mime = '';
|
var mime = '';
|
||||||
if (this.options.mime.indexOf("/") != 0) {
|
if (this.options.mime.indexOf("/") != 0) {
|
||||||
// Lower case it now, if it's not a regex
|
// Lower case it now, if it's not a regex
|
||||||
|
@ -403,6 +403,8 @@ export class et2_file extends et2_inputWidget
|
|||||||
*/
|
*/
|
||||||
checkMime(f)
|
checkMime(f)
|
||||||
{
|
{
|
||||||
|
if(!this.options.mime) return true;
|
||||||
|
|
||||||
let mime: string | RegExp = '';
|
let mime: string | RegExp = '';
|
||||||
if(this.options.mime.indexOf("/") != 0)
|
if(this.options.mime.indexOf("/") != 0)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user