mirror of
https://github.com/bitwarden/mobile
synced 2025-12-05 23:53:33 +00:00
null checked all the permissions (#1227)
This commit is contained in:
@@ -26,7 +26,7 @@ namespace Bit.Core.Models.Data
|
|||||||
Seats = response.Seats;
|
Seats = response.Seats;
|
||||||
MaxCollections = response.MaxCollections;
|
MaxCollections = response.MaxCollections;
|
||||||
MaxStorageGb = response.MaxStorageGb;
|
MaxStorageGb = response.MaxStorageGb;
|
||||||
Permissions = response.Permissions;
|
Permissions = response.Permissions ?? new Permissions();
|
||||||
}
|
}
|
||||||
|
|
||||||
public string Id { get; set; }
|
public string Id { get; set; }
|
||||||
@@ -46,6 +46,6 @@ namespace Bit.Core.Models.Data
|
|||||||
public int Seats { get; set; }
|
public int Seats { get; set; }
|
||||||
public int MaxCollections { get; set; }
|
public int MaxCollections { get; set; }
|
||||||
public short? MaxStorageGb { get; set; }
|
public short? MaxStorageGb { get; set; }
|
||||||
public Permissions Permissions { get; set; }
|
public Permissions Permissions { get; set; } = new Permissions();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -26,7 +26,7 @@ namespace Bit.Core.Models.Domain
|
|||||||
Seats = obj.Seats;
|
Seats = obj.Seats;
|
||||||
MaxCollections = obj.MaxCollections;
|
MaxCollections = obj.MaxCollections;
|
||||||
MaxStorageGb = obj.MaxStorageGb;
|
MaxStorageGb = obj.MaxStorageGb;
|
||||||
Permissions = obj.Permissions;
|
Permissions = obj.Permissions ?? new Permissions();
|
||||||
}
|
}
|
||||||
|
|
||||||
public string Id { get; set; }
|
public string Id { get; set; }
|
||||||
@@ -46,7 +46,7 @@ namespace Bit.Core.Models.Domain
|
|||||||
public int Seats { get; set; }
|
public int Seats { get; set; }
|
||||||
public int MaxCollections { get; set; }
|
public int MaxCollections { get; set; }
|
||||||
public short? MaxStorageGb { get; set; }
|
public short? MaxStorageGb { get; set; }
|
||||||
public Permissions Permissions { get; set; }
|
public Permissions Permissions { get; set; } = new Permissions();
|
||||||
|
|
||||||
public bool CanAccess
|
public bool CanAccess
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -23,6 +23,6 @@ namespace Bit.Core.Models.Response
|
|||||||
public OrganizationUserStatusType Status { get; set; }
|
public OrganizationUserStatusType Status { get; set; }
|
||||||
public OrganizationUserType Type { get; set; }
|
public OrganizationUserType Type { get; set; }
|
||||||
public bool Enabled { get; set; }
|
public bool Enabled { get; set; }
|
||||||
public Permissions Permissions { get; set; }
|
public Permissions Permissions { get; set; } = new Permissions();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user