     # @return {Any}
     ###
     setItem: (key, value) ->
-      window.localStorage.setItem(key, JSON.stringify(value))
+      window.localStorage.setItem(key, angular.toJson(value))
 
     # ### Remove Item
     ###

      #     value = window.localStorage.getItem(key)
      #     value && JSON.parse(value)
      #   setItem: (key, value) ->
      #     window.localStorage.setItem(key, JSON.stringify(value))
      #   removeItem: (key) ->
      #     window.localStorage.removeItem(key)
      #

          catch e
            return $q.reject e.message || e

        return $http.put(_url, angular.toJson(entry), options)
        .then ({status, data}) ->
          data = config.transformResponse(data, 'save')

