remove unused import
remove duplicate cast
small refactoring to use UtilJ.toBool()