Fix "post from URL"
This commit is contained in:
parent
a2cacec59a
commit
382c4f8f3c
@ -6302,7 +6302,7 @@
|
|||||||
return $.addClass(QR.nodes.el, 'dump');
|
return $.addClass(QR.nodes.el, 'dump');
|
||||||
},
|
},
|
||||||
handleBlob: function(urlBlob, header, url) {
|
handleBlob: function(urlBlob, header, url) {
|
||||||
var blob, end, endnl, endsc, mime, name, name_end, name_start, start, _ref;
|
var blob, end, endnl, endsc, mime, name, name_end, name_start, start;
|
||||||
name = url.substr(url.lastIndexOf('/') + 1, url.length);
|
name = url.substr(url.lastIndexOf('/') + 1, url.length);
|
||||||
start = header.indexOf("Content-Type: ") + 14;
|
start = header.indexOf("Content-Type: ") + 14;
|
||||||
endsc = header.substr(start, header.length).indexOf(";");
|
endsc = header.substr(start, header.length).indexOf(";");
|
||||||
@ -6324,9 +6324,6 @@
|
|||||||
if (blob.type === null) {
|
if (blob.type === null) {
|
||||||
return QR.error("Unsupported file type.");
|
return QR.error("Unsupported file type.");
|
||||||
}
|
}
|
||||||
if (_ref = blob.type, __indexOf.call(QR.mimeTypes, _ref) < 0) {
|
|
||||||
return QR.error("Unsupported file type.");
|
|
||||||
}
|
|
||||||
return QR.handleFiles([blob]);
|
return QR.handleFiles([blob]);
|
||||||
},
|
},
|
||||||
handleUrl: function() {
|
handleUrl: function() {
|
||||||
|
|||||||
@ -6366,7 +6366,7 @@
|
|||||||
return $.addClass(QR.nodes.el, 'dump');
|
return $.addClass(QR.nodes.el, 'dump');
|
||||||
},
|
},
|
||||||
handleBlob: function(urlBlob, header, url) {
|
handleBlob: function(urlBlob, header, url) {
|
||||||
var blob, end, endnl, endsc, mime, name, name_end, name_start, start, _ref;
|
var blob, end, endnl, endsc, mime, name, name_end, name_start, start;
|
||||||
name = url.substr(url.lastIndexOf('/') + 1, url.length);
|
name = url.substr(url.lastIndexOf('/') + 1, url.length);
|
||||||
start = header.indexOf("Content-Type: ") + 14;
|
start = header.indexOf("Content-Type: ") + 14;
|
||||||
endsc = header.substr(start, header.length).indexOf(";");
|
endsc = header.substr(start, header.length).indexOf(";");
|
||||||
@ -6388,9 +6388,6 @@
|
|||||||
if (blob.type === null) {
|
if (blob.type === null) {
|
||||||
return QR.error("Unsupported file type.");
|
return QR.error("Unsupported file type.");
|
||||||
}
|
}
|
||||||
if (_ref = blob.type, __indexOf.call(QR.mimeTypes, _ref) < 0) {
|
|
||||||
return QR.error("Unsupported file type.");
|
|
||||||
}
|
|
||||||
return QR.handleFiles([blob]);
|
return QR.handleFiles([blob]);
|
||||||
},
|
},
|
||||||
handleUrl: function() {
|
handleUrl: function() {
|
||||||
|
|||||||
@ -308,8 +308,6 @@ QR =
|
|||||||
|
|
||||||
return if blob.type is null
|
return if blob.type is null
|
||||||
QR.error "Unsupported file type."
|
QR.error "Unsupported file type."
|
||||||
return unless blob.type in QR.mimeTypes
|
|
||||||
QR.error "Unsupported file type."
|
|
||||||
QR.handleFiles([blob])
|
QR.handleFiles([blob])
|
||||||
|
|
||||||
handleUrl: ->
|
handleUrl: ->
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user