remove irrelevant test

second param to hash can be a number of salt rounds
simplify check for valid callback

code cleanup