fixed how singlepage mode turns on/off