Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(api): analytics module #6684

Merged
merged 1 commit into from
Oct 13, 2024
Merged

fix(api): analytics module #6684

merged 1 commit into from
Oct 13, 2024

Conversation

scopsy
Copy link
Contributor

@scopsy scopsy commented Oct 13, 2024

What changed? Why was the change needed?

Mis import of the analytics module, caused FE events to be dismissed.

Screenshots

Expand for optional sections

Related enterprise PR

Special notes for your reviewer

Copy link

netlify bot commented Oct 13, 2024

Deploy Preview for novu-stg-vite-dashboard-poc ready!

Name Link
🔨 Latest commit b7b028f
🔍 Latest deploy log https://app.netlify.com/sites/novu-stg-vite-dashboard-poc/deploys/670bda83dda855000803f15a
😎 Deploy Preview https://deploy-preview-6684--novu-stg-vite-dashboard-poc.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link
Contributor

@djabarovgeorge djabarovgeorge left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

importing a custom analyticsService provider won't be enough?

controllers: [AnalyticsController],
providers: [AnalyticsService, HubspotIdentifyFormUsecase],
providers: [HubspotIdentifyFormUsecase],
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
providers: [HubspotIdentifyFormUsecase],
providers: [analyticsService, HubspotIdentifyFormUsecase],

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

feels like you were missing the process.env.SEGMENT_TOKEN injection? was there something else?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's already imported under the SharedModule, so I think I would love to have a single instance of it

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's confusing, but that's how all of our service are exported from app generic

CleanShot 2024-10-13 at 17 41 30@2x

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

got it, i was not sure if it would create 2 instances.


@Module({
imports: [HttpModule],
imports: [SharedModule, HttpModule],
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
imports: [SharedModule, HttpModule],
imports: [HttpModule],

@scopsy scopsy merged commit 371feea into next Oct 13, 2024
33 checks passed
@scopsy scopsy deleted the fix-analytics-module branch October 13, 2024 14:49
tatarco pushed a commit that referenced this pull request Oct 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants