even more code cleanup