cleanup: avoid redundant lookups