Bug.update_attachment causes error when updating filename using key 'file_name'

RESOLVED FIXED in Bugzilla 5.0

Status

()

RESOLVED FIXED
5 years ago
5 years ago

People

(Reporter: dkl, Assigned: dkl)

Tracking

Bugzilla 5.0
Dependency tree / graph
Bug Flags:
approval +

Details

Attachments

(1 attachment)

(Assignee)

Description

5 years ago
When I was reviewing this new feature I failed to test the changing of the file name. The documentation states to use 'file_name' as the parameter but internally it is 'filename'. 

So I get the error:
The requested method 'Bugzilla::Attachment::set_file_name' was not found.

I will create a patch that converts 'file_name' to 'filename' before set_all() so that we can keep the param naming for attachments consistent.

dkl

Updated

5 years ago
Depends on: 914986
Target Milestone: --- → Bugzilla 5.0

Comment 1

5 years ago
+1 for this.

This should be the same name for add_attachment and update_attachment. Please change this or correct the POD!
(Assignee)

Comment 2

5 years ago
Created attachment 806225 [details] [diff] [review]
917483_1.patch
Assignee: webservice → dkl
Status: NEW → ASSIGNED
Attachment #806225 - Flags: review?(simon)
(Assignee)

Updated

5 years ago
Blocks: 915685

Updated

5 years ago
Attachment #806225 - Flags: review?(simon) → review+

Updated

5 years ago
Flags: approval?

Updated

5 years ago
Blocks: 919357

Updated

5 years ago
No longer blocks: 919357

Updated

5 years ago
Flags: approval? → approval+
(Assignee)

Comment 3

5 years ago
Committing to: bzr+ssh://dlawrence%40mozilla.com@bzr.mozilla.org/bugzilla/trunk
modified Bugzilla/WebService/Bug.pm
Committed revision 8762.
Status: ASSIGNED → RESOLVED
Last Resolved: 5 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.