Skip to content

Commit

Permalink
refactor: used new decorate function for distributed services in KDK
Browse files Browse the repository at this point in the history
  • Loading branch information
claustres committed Dec 23, 2024
1 parent 429d8ef commit 6d2b3ae
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion api/src/services/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -355,7 +355,8 @@ export default async function () {
// Make remote services compliant with our internal app services so that permissions can be used
if (service.key === 'kano' || service.key === 'weacast') {
debug('Configuring remote service', service)
decorateDistributedService.call(app, service)
// Jump from remote service descriptor to actual service instance
service = decorateDistributedService.call(app, service)
// Register default permissions for it
debug('Registering permissions for remote service ', service.name)
permissions.defineAbilities.registerHook((subject, can, cannot) => {
Expand Down

0 comments on commit 6d2b3ae

Please sign in to comment.