https://bugzilla.wikimedia.org/show_bug.cgi?id=14925
--- Comment #11 from Tim Starling <[email protected]> 2008-12-17 04:45:28 UTC --- * Update the patch and Upload*.php, needs to incorporate SpecialUpload.php changes between r41253 and r44701 * UploadForm::internalProcessUpload() has too much boilerplate, which would have to be reproduced in each new UI component. I suggest merging verifyPermissions(), fetchFile(), verifyUpload(), checkWarnings(), performUpload() and cleanupTempFile() into a single function. It should accept an associative array as its parameter, with members such as initial page text, ignore warnings, comment and user. Preferably it would return a Status object. * Get rid of the UploadBase status constants, they're not extensible. Use message names for status codes. You can wrap them in Status objects where convenient. * Fix the UploadBase::BEFORE_PROCESSING case in processUpload() * Fix stupid comment "It will show an error form on failure. No it will not." * Rename UploadFromStash to UploadFromSession, document it to the point where ordinary humans might be able to work out how to use it. Rename stashSession() to createSession(), rename unsaveUploadedFile() to destroySession(). Document UploadFromSession::initialize(). Document the fact that these three functions go together. * Suggest renaming "UploadFromUpload" to something less vague, maybe "UploadFromWebForm" * "Upload handlers. Should probably just be a global" -- indeed it should, then it would be extensible. But the global should allow for arbitrary class names, instead of prepending "UploadFrom", so that extensions can maintain a naming scheme where class names start with the name of the extension. * Document all functions, including parameter definitions, with an extension writer audience in mind. It won't take long. -- Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug. _______________________________________________ Wikibugs-l mailing list [email protected] https://lists.wikimedia.org/mailman/listinfo/wikibugs-l
