Bug 990373

Summary: Source file Upload dialog will cause an exception if filename is not set
Product: [Retired] Zanata Reporter: Damian Jansen <djansen>
Component: UsabilityAssignee: David Mason <damason>
Status: CLOSED CURRENTRELEASE QA Contact: Zanata-QA Mailling List <zanata-qa>
Severity: medium Docs Contact:
Priority: medium    
Version: developmentCC: damason, zanata-bugs
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-11-27 03:31:24 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 994362    

Description Damian Jansen 2013-07-31 05:31:11 UTC
Description of problem:
A NullPointerException will occur if the user presses Upload without setting a file

Version-Release number of selected component (if applicable):
Dev

How reproducible:
Easy always

Steps to Reproduce:
1. Go to Projects and select (or create) a project
2. Select or create a project version
3. Go to Source Documents
4. Press Upload Document
5. Press Upload button

Actual results:
Unexpected error. Please try again. [ Request: ? ] 

Expected results:
Either the button should be greyed out, or a message saying "Please select a file to upload" should show.

Additional info:

Comment 1 David Mason 2013-08-02 06:23:35 UTC
Fixed in 3.0.0-alpha-2-SNAPSHOT by disabling the upload button whenever the file selection element does not specify a file.

See: https://github.com/zanata/zanata-server/commit/9620e5e7f9d92fe90152f99e26eafc3a62fe0f88

Comment 2 Damian Jansen 2013-08-07 06:21:03 UTC
Verified at 5bf0f1eadda3c43c780c06cdbdb9746bae49215d

Comment 3 Sean Flanigan 2013-11-27 03:31:24 UTC
Closing VERIFIED bugs which predate Zanata 3.1.2.