Stats form changes and some warning refactoring