cache the current user right in the beginning
refactor the service into more idiomatic javascript