Checks for 'invalid' selected IDs that need to be skipped were incomplete, and one was missing the actual return statement.