Changed default permission
Removed unused code