removed null check
This commit is contained in:
@@ -128,14 +128,21 @@ public class LightlessPlugin : MediatorSubscriberBase, IHostedService
|
|||||||
Logger.LogInformation("User has valid setup: {hasValidSetup}", _lightlessConfigService.Current.HasValidSetup());
|
Logger.LogInformation("User has valid setup: {hasValidSetup}", _lightlessConfigService.Current.HasValidSetup());
|
||||||
Logger.LogInformation("Server has valid config: {hasValidConfig}", _serverConfigurationManager.HasValidConfig());
|
Logger.LogInformation("Server has valid config: {hasValidConfig}", _serverConfigurationManager.HasValidConfig());
|
||||||
// Show update notes if version has changed and user has valid setup
|
// Show update notes if version has changed and user has valid setup
|
||||||
if (!string.IsNullOrEmpty(lastSeen) &&
|
if (!string.Equals(lastSeen, currentVersion, StringComparison.Ordinal) &&
|
||||||
!string.Equals(lastSeen, currentVersion, StringComparison.Ordinal) &&
|
|
||||||
_lightlessConfigService.Current.HasValidSetup() &&
|
_lightlessConfigService.Current.HasValidSetup() &&
|
||||||
_serverConfigurationManager.HasValidConfig())
|
_serverConfigurationManager.HasValidConfig())
|
||||||
|
{
|
||||||
|
// Update the last seen version to current version
|
||||||
|
_lightlessConfigService.Current.LastSeenVersion = currentVersion;
|
||||||
|
_lightlessConfigService.Save();
|
||||||
|
|
||||||
|
// Only show update notes if this isn't the first run
|
||||||
|
if (!string.IsNullOrEmpty(lastSeen))
|
||||||
{
|
{
|
||||||
Mediator.Publish(new UiToggleMessage(typeof(UpdateNotesUi)));
|
Mediator.Publish(new UiToggleMessage(typeof(UpdateNotesUi)));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
private void DalamudUtilOnLogIn()
|
private void DalamudUtilOnLogIn()
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user