Redmine: Issueshttps://www.redmine.org/https://www.redmine.org/favicon.ico?16793021292010-04-09T10:41:44ZRedmine
Redmine Redmine - Defect #5280 (Closed): Issue lock_version not workinghttps://www.redmine.org/issues/52802010-04-09T10:41:44ZTim Coleman
<p>I'm finding that on trunk the lock_version of the Issue model isn't being taken into account, meaning that different users can make conflicting changes to issues without any notice from redmine.</p>
<p>I've only had a cursory look at the source, but it looks like lock_version should perhaps be a safe attribute (see <a class="changeset" title="Set a white list of issue attributes that can be mass-assigned from controllers." href="https://www.redmine.org/projects/redmine/repository/svn/revisions/3308">r3308</a>), otherwise it never gets set from the request params.</p>
<p>Additionally (perhaps this should be a different bug?) once the lock_version is accepted as a safe attribute, the stale object exception handler in IssuesContoller::update attempts to read a non-existant variable 'attachments'. It looks like that variable was refactored away to the Issue model in <a class="changeset" title="Refactor: Moved the contents of #issue_update into Issue." href="https://www.redmine.org/projects/redmine/repository/svn/revisions/3545">r3545</a></p>