added extra cases to join