1
0
mirror of https://github.com/bitwarden/server.git synced 2025-04-17 11:08:16 -05:00

null check on license key

This commit is contained in:
Kyle Spearrin 2018-07-20 13:58:24 -04:00
parent 29d62be82c
commit 45db73c6e1
2 changed files with 2 additions and 2 deletions

View File

@ -188,7 +188,7 @@ namespace Bit.Core.Models.Business
{ {
var valid = var valid =
globalSettings.Installation.Id == InstallationId && globalSettings.Installation.Id == InstallationId &&
organization.LicenseKey.Equals(LicenseKey) && organization.LicenseKey != null && organization.LicenseKey.Equals(LicenseKey) &&
organization.Enabled == Enabled && organization.Enabled == Enabled &&
organization.PlanType == PlanType && organization.PlanType == PlanType &&
organization.Seats == Seats && organization.Seats == Seats &&

View File

@ -134,7 +134,7 @@ namespace Bit.Core.Models.Business
if(Version == 1) if(Version == 1)
{ {
return return
user.LicenseKey.Equals(LicenseKey) && user.LicenseKey != null && user.LicenseKey.Equals(LicenseKey) &&
user.Premium == Premium && user.Premium == Premium &&
user.Email.Equals(Email, StringComparison.InvariantCultureIgnoreCase); user.Email.Equals(Email, StringComparison.InvariantCultureIgnoreCase);
} }