mirror of
https://github.com/bitwarden/server.git
synced 2025-04-07 05:58:13 -05:00
storageBytesRemaining by way of users get premium
This commit is contained in:
parent
db3316dd60
commit
0983a35cf3
@ -133,7 +133,16 @@ namespace Bit.Core.Services
|
|||||||
throw new BadRequestException("You must have premium status to use attachments.");
|
throw new BadRequestException("You must have premium status to use attachments.");
|
||||||
}
|
}
|
||||||
|
|
||||||
storageBytesRemaining = user.StorageBytesRemaining();
|
if(user.Premium)
|
||||||
|
{
|
||||||
|
storageBytesRemaining = user.StorageBytesRemaining();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
// Users that get access to file storage/premium from their organization get the default
|
||||||
|
// 1 GB max storage.
|
||||||
|
storageBytesRemaining = user.StorageBytesRemaining(1);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else if(cipher.OrganizationId.HasValue)
|
else if(cipher.OrganizationId.HasValue)
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user