adjust logic to be consistent with rest of codebase