Skip to content

Commit

Permalink
Fix hubspot routing
Browse files Browse the repository at this point in the history
  • Loading branch information
anthonyec committed Sep 26, 2024
1 parent cc5ff23 commit 8957ca3
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
2 changes: 1 addition & 1 deletion plugins/hubspot/src/auth.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ export interface Authorize {

const pluginTokensKey = "hubspotTokens"

export const isLocal = () => window.location.hostname.includes("localhost")
const isLocal = () => window.location.hostname.includes("localhost")

export const AUTH_URI = isLocal() ? "https://localhost:8787" : "https://oauth.fetch.tools/hubspot-plugin"

Expand Down
3 changes: 1 addition & 2 deletions plugins/hubspot/src/router.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ import { LearnMoreTrackingPage } from "./pages/tracking/learn-more"
import { MeetingsPage } from "./pages/Meetings"
import { PluginPage } from "./components/PluginPage"
import { PageErrorBoundaryFallback } from "./components/PageErrorBoundaryFallback"
import { isLocal } from "./auth"

interface PluginRoute {
path: string
Expand All @@ -28,7 +27,7 @@ interface Match {

const pluginRoutes: PluginRoute[] = [
{
path: isLocal() ? "/" : "/hubspot",
path: "/",
component: AuthenticatePage,
},
{
Expand Down

0 comments on commit 8957ca3

Please sign in to comment.