small refactors on crate