some features and cleanups