Common.credentials synchronicity issues.

fixes #139 #142 
Updated some spacing and indentions (mixed tabs and spaces)
Updated both view files to use UNIX line endings instead of DOS
Fixed all issues with Common.credentials type
Fixed synchronicity issues with sessionStorage and Common.cache