move duplicate logic into `_bind` function