Fixed #7823 -- Fixed an edge case in RelatedField.get_db_prep_lookup() so that