From f26256f55a3a1c5c403cb6292018a369d47bc812 Mon Sep 17 00:00:00 2001 From: 8chan Date: Thu, 19 Mar 2015 20:22:17 -0700 Subject: [PATCH] Make file selector work, add to config Conflicts: inc/instance-config.php templates/post_form.html --- js/file-selector.js | 4 ++-- templates/post_form.html | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/js/file-selector.js b/js/file-selector.js index dbe8ea82..687920d0 100644 --- a/js/file-selector.js +++ b/js/file-selector.js @@ -5,7 +5,7 @@ * $config['additional_javascript'][] = 'js/jquery.min.js'; * $config['additional_javascript'][] = 'js/file-selector.js'; */ -function init_file_selector() { +function init_file_selector(max_images) { $(document).ready(function () { // add options panel item @@ -20,7 +20,7 @@ $(document).ready(function () { } }); - if (localStorage.file_dragdrop === 'undefined') localStorage.file_dragdrop = 'true'; + if (typeof localStorage.file_dragdrop === 'undefined') localStorage.file_dragdrop = 'true'; if (localStorage.file_dragdrop === 'true') $('#file-drag-drop>input').prop('checked', true); } }); diff --git a/templates/post_form.html b/templates/post_form.html index 7cdcc7d3..00390daf 100644 --- a/templates/post_form.html +++ b/templates/post_form.html @@ -106,7 +106,7 @@ - + {% if config.allow_upload_by_url %}