Correct initial view depending on the 'view' attribute