added premissions
minor fixes