cleanup: change `var` into `val`, because we can
remove unused imports
remove unused code