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

refactor: Port MPILogger to Swift #295

Merged
merged 4 commits into from
Sep 30, 2024

Conversation

BrandonStalnaker
Copy link
Contributor

Summary

  • Port MPILogger to Swift. Do not replace existing implementation as Swift version can only be used in Swift.

Testing Plan

  • Tested on sample app in simulator. Confirmed all unit tests as well

Reference Issue (For mParticle employees only. Ignore if you are an outside contributor)

Comment on lines 15 to 18
// Custom Logger is marked as nonnull despite the fact that we expect it to be null if not set by the client
// if let customLogger = MParticle.sharedInstance().customLogger {
// customLogger(msg)
// } else
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
// Custom Logger is marked as nonnull despite the fact that we expect it to be null if not set by the client
// if let customLogger = MParticle.sharedInstance().customLogger {
// customLogger(msg)
// } else

I assume this was meant to be deleted?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

no I wanted to leave this here to make sure we understood this is kinda a todo once we fully convert to Swift

mParticle-Apple-SDK/Logger/MPLogger.swift Outdated Show resolved Hide resolved
@BrandonStalnaker
Copy link
Contributor Author

Addressed comments ready for a new look @einsteinx2

@BrandonStalnaker BrandonStalnaker force-pushed the refactor/6733-Swift-Port-MPILogger branch from 574f54e to 2e9bb13 Compare September 30, 2024 16:37
Copy link
Contributor

@einsteinx2 einsteinx2 left a comment

Choose a reason for hiding this comment

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

Changed nullability in public interface per my request. LGTM

@BrandonStalnaker BrandonStalnaker merged commit 7828fed into development Sep 30, 2024
11 checks passed
@BrandonStalnaker BrandonStalnaker deleted the refactor/6733-Swift-Port-MPILogger branch September 30, 2024 16:55
@mparticle-automation
Copy link
Contributor

🎉 This PR is included in version 8.27.2 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants