Skip to content

Commit

Permalink
Merge pull request #612 from bcgov/yj
Browse files Browse the repository at this point in the history
fix: unlink biz lic
  • Loading branch information
ychung-mot authored Sep 9, 2024
2 parents 9f487f6 + 3de2b29 commit fb92f33
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 9 deletions.
8 changes: 4 additions & 4 deletions postgres/values-dev.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,17 @@ primary:
containerSecurityContext:
enabled: false
persistence:
size: 400Mi
size: 800Mi
resources:
limits:
cpu: 150m
memory: 300Mi
memory: 1Gi
requests:
cpu: 50m
memory: 250Mi
memory: 700Mi
readReplicas:
persistence:
size: 400Mi
size: 800Mi
nameOverride: strdssdev
fullnameOverride: strdssdev
annotations:
Expand Down
6 changes: 3 additions & 3 deletions postgres/values-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,13 @@ primary:
resources:
limits:
cpu: 150m
memory: 300Mi
memory: 1Gi
requests:
cpu: 50m
memory: 250Mi
memory: 700Mi
readReplicas:
persistence:
size: 400Mi
size: 800Mi
nameOverride: strdsstest
fullnameOverride: strdsstest
annotations:
Expand Down
5 changes: 3 additions & 2 deletions server/StrDss.Data/Repositories/RentalListingRepository.cs
Original file line number Diff line number Diff line change
Expand Up @@ -766,9 +766,10 @@ public async Task LinkBizLicence(long rentalListingId, long licenceId)
public async Task UnLinkBizLicence(long rentalListingId)
{
//assume it exists - validated already
var listing = await _dbContext.DssRentalListings.FirstAsync(x => x.RentalListingId == rentalListingId);
var listing = await _dbContext.DssRentalListings
.FirstAsync(x => x.RentalListingId == rentalListingId);

if (listing.GoverningBusinessLicenceId != null)
if (listing.GoverningBusinessLicenceId == null)
return;

listing.GoverningBusinessLicenceId = null;
Expand Down

0 comments on commit fb92f33

Please sign in to comment.