Use the permission mechanism instead of local storage for storing preferences