Debugging the view controller malfunction