From: Jan Gerber Date: Tue, 21 Jul 2009 15:51:00 +0000 (+0000) Subject: only set wpDestFile after selecting a file if its empty -- this could have been set... X-Git-Tag: 1.31.0-rc.0~40784 X-Git-Url: http://git.cyclocoop.org/%7D%7Cconcat%7B?a=commitdiff_plain;h=c2e75ab06fbd332d7b70d9d26417b59e3d61dbaf;p=lhc%2Fweb%2Fwiklou.git only set wpDestFile after selecting a file if its empty -- this could have been set via url /index.php?title=Special:Upload&wpDestFile=foobar.ogv --- diff --git a/js2/uploadPage.js b/js2/uploadPage.js index a374d9a35a..2dc5e484c1 100644 --- a/js2/uploadPage.js +++ b/js2/uploadPage.js @@ -21,7 +21,8 @@ var mwUploadHelper = { 'api_url' : wgServer + wgScriptPath + '/api.php', 'form_rewrite': true, 'new_source_cb' : function( orgFilename, oggName ){ - $j('#wpDestFile').val( oggName ); + if($j('#wpDestFile').val() == "") + $j('#wpDestFile').val( oggName ); mwUploadHelper.doDestCheck(); }, 'detect_cb':function(fogg_installed){