Implemented proper error handling for the UiContext constructor
Merge pull request #161 from mitchmindtree/master

Implemented proper error handling for the UiContext constructor