Files
notifications-admin/app/models
Chris Hill-Scott b7e9c320f8 Fix permissions check when service ID is a UUID
If you define a route with the service ID as a typed parameter, ie
```
@main.route('/services/<uuid:service_id>/agreement')
```

then `type(service_id)` returns `<class 'uuid.UUID'>`.

This is a problem when the permissions dictionary stores service IDs as
strings, because trying to look up a user’s permissions with the UUID
fails silently (that key isn’t in the dictionary).

This commit makes sure we always cast the service ID to a string before
using it to check permissions.
2019-05-03 10:06:51 +01:00
..