Modified singleton pattern application. Previously it was not enforcing
that only one instance could exist.