- Applied some principles of DRY. (Converted factories into a single factory)
 - Moved localStorage code into a service.
Merge pull request #1 from shyamsalimkumar/DRY

DRY changes and service creation.