message: Fix issue getting updated org in UI
diff: @@ -29,7 +29,6 @@ const ProfileSection = (props: Props) => {
  }
  };
  - useEffect(() => {
  async function fetchOrganization() {
  try {
  setIsLoading(true);
  @@ -48,10 +47,15 @@ const ProfileSection = (props: Props) => {
  }
  }
  }
  - if (!isUndefined(selectedOrg)) {
  +
  + useEffect(() => {
  + if (
  + !isUndefined(selectedOrg) &&
  + (isUndefined(organization) || (!isNull(organization) && selectedOrg !== organization.name))
  + ) {
  fetchOrganization();
  }
  - }, [props, selectedOrg]);
  + }, [selectedOrg]); /* eslint-disable-line react-hooks/exhaustive-deps */
  return (
  <main role="main" className="container p-0">
  @@ -73,6 +77,7 @@ const ProfileSection = (props: Props) => {
  ref={form}
  organization={!isLoading ? organization : undefined}
  onAuthError={props.onAuthError}
  + onSuccess={fetchOrganization}
  setIsSending={setIsSending}
  />
  )}
  