minor optimization of code format and imports