Improvements on data permissions (working ok)