Skip to content
Snippets Groups Projects
Commit 93ac1183 authored by Elia AZAR's avatar Elia AZAR
Browse files

groups.ts -> memberOfMeta

parent 40e48605
No related branches found
No related tags found
No related merge requests found
...@@ -627,7 +627,12 @@ export class SimpleGroup extends Group { ...@@ -627,7 +627,12 @@ export class SimpleGroup extends Group {
*/ */
async memberOfMeta(args, context: Context, info): Promise<MetaGroup[]> { async memberOfMeta(args, context: Context, info): Promise<MetaGroup[]> {
if(context.models.auth.isViewer(this.gid)) { if(context.models.auth.isViewer(this.gid)) {
throw "Not implemented"; let arg = await context.models.group.getAllMetaGroups(this.gid);
let res = new Array<MetaGroup>();
for(let g of arg){
res.push(new MetaGroup(g));
}
return res;
} }
throw new AuthenticationError("Not a viewer"); throw new AuthenticationError("Not a viewer");
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment