goodeggs / angular-cached-resource

An AngularJS module to interact with RESTful resources, even when browser is offline
MIT License
216 stars 29 forks source link

Error when cacheKey contains multiple underscores #41

Open antonsamper opened 10 years ago

antonsamper commented 10 years ago

There is a strange bug when you add a custom cache key with multiple single underscores. It took me ages to track it down so hopefully it will help someone else.

The following cache key works: EXAMPLE_ONEUNDERSCORE__TWOUNDERSCORES However, this one doesn't: EXAMPLE_ONEUNDERSCORE_ONEUNDERSCORE

There seems to be something strange going on with the underscores when you have more than one single underscores.

hazeledmands commented 10 years ago

Bizarre, thanks for the report!