spumko/hapi — pull request #1185 by nlf (2013-12-03 23:45:52+00:00)
Title: be more careful about options in _provisionCache

I just spent the better part of an hour tracking down a bug, only to find it was due to the difference between server.cache and plugin.cache. Turns out if you call

```js
var cache = plugin.cache('name', { /* options */ });
```

Nothing complains, despite the string ```'name'``` being sent as the options object to _provisionCache. This means that the ttl ends up defaulting to 0 and your cache basically doesn't store anything. This quick little change at least made it so it would catch my boneheaded mistake if I do it again in the future.