Skip to content

Commit

Permalink
[dashboard] compute useIsGithubAppEnabled on FE
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexTugarev committed Nov 14, 2023
1 parent 0ec0037 commit 61d50ae
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@ import { useCurrentUser } from "../../user-context";

export const useIsGithubAppEnabled = () => {
return useQuery(["github-app-enabled"], async () => {
return await getGitpodService().server.isGitHubAppEnabled();
// similar to `isGitpodio`, but the GH App is only configured on Cloud.
return window.location.hostname === "gitpod.io" || window.location.hostname === "gitpod-staging.com";
});
};

Expand Down

0 comments on commit 61d50ae

Please sign in to comment.