0
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2025-02-10 23:36:14 -05:00

Fixing URL-based image uploads on settings screen

This commit is contained in:
Hannah Wolfe 2013-10-17 21:54:51 +01:00
parent 4f8ac2a4fd
commit f12a3cecf7

View file

@ -204,8 +204,8 @@
var self = this, upload = new Ghost.Models.uploadModal({'key': key, 'src': src, 'accept': {
func: function () { // The function called on acceptance
var data = {};
if (this.$('#uploadurl').val()) {
data[key] = this.$('#uploadurl').val();
if (this.$('.js-upload-url').val()) {
data[key] = this.$('.js-upload-url').val();
} else {
data[key] = this.$('.js-upload-target').attr('src');
}
@ -263,8 +263,8 @@
var self = this, upload = new Ghost.Models.uploadModal({'key': key, 'src': src, 'accept': {
func: function () { // The function called on acceptance
var data = {};
if (this.$('#uploadurl').val()) {
data[key] = this.$('#uploadurl').val();
if (this.$('.js-upload-url').val()) {
data[key] = this.$('.js-upload-url').val();
} else {
data[key] = this.$('.js-upload-target').attr('src');
}