Skip to content

fix: Rename internal SetupLogging to SetupUnityLogging #2096

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

Merged
merged 2 commits into from
Apr 3, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/Sentry.Unity/ScriptableSentryUnityOptions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,7 @@ internal SentryUnityOptions ToSentryUnityOptions(bool isBuilding, ISentryUnityIn

// We need to set up logging here because the configure callback might have changed the debug options.
// Without setting up here we might miss out on logs between option-loading (now) and Init - i.e. native configuration
options.SetupLogging();
options.SetupUnityLogging();

if (options.AttachViewHierarchy)
{
Expand Down
2 changes: 1 addition & 1 deletion src/Sentry.Unity/SentryUnityOptionsExtensions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ internal static bool IsValid(this SentryUnityOptions options)
return true;
}

internal static void SetupLogging(this SentryUnityOptions options)
internal static void SetupUnityLogging(this SentryUnityOptions options)
{
if (options.Debug)
{
Expand Down
2 changes: 1 addition & 1 deletion src/Sentry.Unity/SentryUnitySDK.cs
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ private SentryUnitySdk(SentryUnityOptions options)
{
var unitySdk = new SentryUnitySdk(options);

options.SetupLogging();
options.SetupUnityLogging();
if (!options.ShouldInitializeSdk())
{
return null;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ public void SetupLogging_DebugAndNoDiagnosticLogger_SetsUnityLogger()

Assert.IsNull(options.DiagnosticLogger); // Sanity check

options.SetupLogging();
options.SetupUnityLogging();

Assert.IsInstanceOf<UnityLogger>(options.DiagnosticLogger);
}
Expand All @@ -111,7 +111,7 @@ public void SetupLogging_DebugFalse_DiagnosticLoggerIsNull()
var options = _fixture.GetSut();
options.DiagnosticLogger = new UnityLogger(options);

options.SetupLogging();
options.SetupUnityLogging();

Assert.IsNull(options.DiagnosticLogger);
}
Expand All @@ -125,7 +125,7 @@ public void SetupLogging_DiagnosticLoggerSet_LeavesOrRemovesDiagnosticLogger(boo
var options = _fixture.GetSut();
options.DiagnosticLogger = new UnityLogger(options);

options.SetupLogging();
options.SetupUnityLogging();

Assert.AreEqual(debug, options.DiagnosticLogger is not null);
}
Expand Down
Loading