move autoLogin to controller.js
modify 'delete-user' ajax.type from 'post' to 'delete'