Skip to content

Commit

Permalink
chore: remove build warnings (#3534)
Browse files Browse the repository at this point in the history
* chore: remove build warnings

* fix: posthog wrapper fixes

---------

Co-authored-by: sriram veeraghanta <[email protected]>
  • Loading branch information
aaryan610 and sriramveeraghanta authored Feb 1, 2024
1 parent b0ad48e commit 7d08a57
Show file tree
Hide file tree
Showing 7 changed files with 9 additions and 9 deletions.
1 change: 1 addition & 0 deletions web/components/core/modals/gpt-assistant-popover.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,7 @@ export const GptAssistantPopover: React.FC<Props> = (props) => {
window.removeEventListener("keydown", handleEnterKeyPress);
window.removeEventListener("keydown", handleEscapeKeyPress);
};
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [isOpen, handleSubmit, onClose]);

const responseActionButton = response !== "" && (
Expand Down
1 change: 0 additions & 1 deletion web/components/dashboard/widgets/overview-stats.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ import { useDashboard } from "hooks/store";
import { WidgetLoader } from "components/dashboard/widgets";
// helpers
import { renderFormattedPayloadDate } from "helpers/date-time.helper";
import { cn } from "helpers/common.helper";
// types
import { TOverviewStatsWidgetResponse } from "@plane/types";

Expand Down
3 changes: 1 addition & 2 deletions web/components/issues/issue-layouts/empty-states/module.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { useState } from "react";
import { observer } from "mobx-react-lite";
import { PlusIcon } from "lucide-react";
// hooks
import { useApplication, useIssueDetail, useIssues, useUser } from "hooks/store";
import { useApplication, useIssues, useUser } from "hooks/store";
import useToast from "hooks/use-toast";
// components
import { EmptyState } from "components/common";
Expand All @@ -29,7 +29,6 @@ export const ModuleEmptyState: React.FC<Props> = observer((props) => {
const [moduleIssuesListModal, setModuleIssuesListModal] = useState(false);
// store hooks
const { issues } = useIssues(EIssuesStoreType.MODULE);
const { updateIssue, fetchIssue } = useIssueDetail();

const {
commandPalette: { toggleCreateIssueModal },
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,7 @@ export const BaseSpreadsheetRoot = observer((props: IBaseSpreadsheetRoot) => {
portalElement={portalElement}
/>
),
// eslint-disable-next-line react-hooks/exhaustive-deps
[handleIssues]
);

Expand Down
1 change: 1 addition & 0 deletions web/components/issues/issue-modal/form.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,7 @@ export const IssueFormRoot: FC<IssueFormProps> = observer((props) => {
parent_id: formData.parent_id,
});
}
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [projectId]);

const issueName = watch("name");
Expand Down
5 changes: 2 additions & 3 deletions web/lib/app-provider.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -47,16 +47,15 @@ export const AppProvider: FC<IAppProvider> = observer((props) => {
<InstanceLayout>
<StoreWrapper>
<CrispWrapper user={currentUser}>
{/* <PosthogWrapper
<PosthogWrapper
user={currentUser}
workspaceRole={currentWorkspaceRole}
projectRole={currentProjectRole}
posthogAPIKey={envConfig?.posthog_api_key || null}
posthogHost={envConfig?.posthog_host || null}
>
<SWRConfig value={SWR_CONFIG}>{children}</SWRConfig>
</PosthogWrapper> */}
<SWRConfig value={SWR_CONFIG}>{children}</SWRConfig>
</PosthogWrapper>
</CrispWrapper>
</StoreWrapper>
</InstanceLayout>
Expand Down
6 changes: 3 additions & 3 deletions web/lib/wrappers/posthog-wrapper.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,9 @@ const PosthogWrapper: FC<IPosthogWrapper> = (props) => {
posthog.init(posthogAPIKey, {
api_host: posthogHost || "https://app.posthog.com",
// Enable debug mode in development
loaded: (posthog) => {
if (process.env.NODE_ENV === "development") posthog.debug();
},
// loaded: (posthog) => {
// if (process.env.NODE_ENV === "development") posthog.debug();
// },
autocapture: false,
capture_pageview: false, // Disable automatic pageview capture, as we capture manually
});
Expand Down

0 comments on commit 7d08a57

Please sign in to comment.