Permission check logic fix
Little cleanup
Readme update