Fix access_locked? always return boolean
Merge pull request #2458 from t-kot/fix_access_locked_return_value

Fix access_locked? always return boolean