tiny refactors and adjustments