diff --git a/zerver/lib/actions.py b/zerver/lib/actions.py index 497e8b2ea9..95ff2b80a9 100644 --- a/zerver/lib/actions.py +++ b/zerver/lib/actions.py @@ -456,7 +456,7 @@ def notify_created_bot(user_profile: UserProfile) -> None: event = created_bot_event(user_profile) send_event(user_profile.realm, event, bot_owner_user_ids(user_profile)) -def create_users(realm: Realm, name_list: Iterable[Tuple[str, str]], bot_type: int=None) -> None: +def create_users(realm: Realm, name_list: Iterable[Tuple[str, str]], bot_type: Optional[int]=None) -> None: user_set = set() for full_name, email in name_list: short_name = email_to_username(email) @@ -5317,7 +5317,7 @@ def notify_realm_custom_profile_fields(realm: Realm, operation: str) -> None: def try_add_realm_custom_profile_field(realm: Realm, name: str, field_type: int, hint: str='', - field_data: ProfileFieldData=None) -> CustomProfileField: + field_data: Optional[ProfileFieldData]=None) -> CustomProfileField: field = CustomProfileField(realm=realm, name=name, field_type=field_type) field.hint = hint if field.field_type == CustomProfileField.CHOICE: @@ -5342,7 +5342,7 @@ def do_remove_realm_custom_profile_fields(realm: Realm) -> None: def try_update_realm_custom_profile_field(realm: Realm, field: CustomProfileField, name: str, hint: str='', - field_data: ProfileFieldData=None) -> None: + field_data: Optional[ProfileFieldData]=None) -> None: field.name = name field.hint = hint if field.field_type == CustomProfileField.CHOICE: