updateProfile method

Future<KuzzleProfile> updateProfile(
  1. String id,
  2. List policies, {
  3. bool? waitForRefresh,
})

Updates a security profile definition.

Implementation

Future<KuzzleProfile> updateProfile(String id, List<dynamic> policies,
    {bool? waitForRefresh}) async {
  final response = await kuzzle.query(KuzzleRequest(
    controller: name,
    action: 'updateProfile',
    uid: id,
    waitForRefresh: waitForRefresh,
    body: <String, dynamic>{
      'policies': policies,
    },
  ));

  return KuzzleProfile.fromKuzzleResponse(kuzzle, response);
}