utils updated to not pollute the global namespace