fix reversed conditions on HASFLOCK settings