Feroze Mohideen 2 years ago
parent
commit
04876c9ed1
1 changed files with 2 additions and 10 deletions
  1. 2 10
      dashboard/src/lib/hooks/usePorterYaml.ts

+ 2 - 10
dashboard/src/lib/hooks/usePorterYaml.ts

@@ -81,16 +81,8 @@ export const usePorterYaml = ({
         source?.type === "github" &&
         Boolean(source.git_repo_name) &&
         Boolean(source.git_branch),
-      retry: (_failureCount, error) => {
-        if (
-          // error response will be 403 status if user does not have access to the github installation
-          error.response?.status === 404 || error.response?.status === 403 ||
-          error.response.data?.error?.includes("not found")
-        ) {
-          setPorterYamlFound(false);
-          return false;
-        }
-        return true;
+      onError: () => {
+        setPorterYamlFound(false);
       },
       refetchOnWindowFocus: false,
     }