Fix for locking issues in redmine/6334

bah, thanks. Brain fart.