Added logic to reject the view loading dfd if the view returned from require is undefined (js error)