@@ -1561,15 +1561,13 @@ class BaseService extends RequestBuilder {
15611561 } ;
15621562 }
15631563 async create ( model , params ) {
1564- if ( params ) {
1565- }
1564+ if ( params ) { }
15661565 const jsonApiSerializer = new JsonApiSerializer ( this . hydrator . getModelMap ( ) ) ;
15671566 const payload = jsonApiSerializer . buildCreatePayload ( model ) ;
15681567 return await this . client . makePostRequest ( this . endpoint , payload ) ;
15691568 }
15701569 async update ( id , model , params ) {
1571- if ( params ) {
1572- }
1570+ if ( params ) { }
15731571 const jsonApiSerializer = new JsonApiSerializer ( this . hydrator . getModelMap ( ) ) ;
15741572 const payload = jsonApiSerializer . buildUpdatePayload ( model ) ;
15751573 return await this . client . makePatchRequest ( `${ this . endpoint } /${ id } ` , payload ) ;
@@ -1767,8 +1765,9 @@ class EquipmentService extends BaseService {
17671765
17681766// src/services/EquipmentExposureService.ts
17691767class EquipmentExposureService extends BaseService {
1770- constructor ( client ) {
1771- super ( client , "/v3/orgs/:orgId/assets/equipment/exposures" ) ;
1768+ constructor ( client , equipmentId ) {
1769+ const endpoint = equipmentId ? `/v3/orgs/:orgId/assets/equipment/${ equipmentId } /exposures` : `/v3/orgs/:orgId/assets/equipment/exposures` ;
1770+ super ( client , endpoint ) ;
17721771 }
17731772}
17741773
@@ -2109,8 +2108,8 @@ class Client {
21092108 equipment ( ) {
21102109 return new EquipmentService ( this ) ;
21112110 }
2112- equipmentExposures ( ) {
2113- return new EquipmentExposureService ( this ) ;
2111+ equipmentExposures ( equipmentId ) {
2112+ return new EquipmentExposureService ( this , equipmentId ) ;
21142113 }
21152114 equipmentManufacturers ( ) {
21162115 return new EquipmentManufacturersService ( this ) ;
@@ -2252,9 +2251,6 @@ class ClientConfig {
22522251}
22532252// src/models/Organisation.ts
22542253class Organisation extends BaseModel {
2255- constructor ( ) {
2256- super ( ...arguments ) ;
2257- }
22582254 type = "organisations" ;
22592255 static relationships = [ ] ;
22602256}
0 commit comments