Simplified code, and support dynamic message cache total count by configuration. :sunglasses:

Configuration fixed in index.js.
Merge pull request #14 from labajo/audit1

Simplified code, and support dynamic message cache total count by configuration.