From 6e9706dc64ab98f93bd2f306d3898c0e1b02c20f Mon Sep 17 00:00:00 2001
From: Harsha Kethineni <harshakethineni@flywheel.io>
Date: Wed, 13 Sep 2017 10:38:52 -0500
Subject: [PATCH] group perm update prop will add perm to projects

---
 api/handlers/listhandler.py | 1 +
 1 file changed, 1 insertion(+)

diff --git a/api/handlers/listhandler.py b/api/handlers/listhandler.py
index 5da8dd75..fb2d5180 100644
--- a/api/handlers/listhandler.py
+++ b/api/handlers/listhandler.py
@@ -229,6 +229,7 @@ class PermissionsListHandler(ListHandler):
         payload['_id'] = kwargs.get('_id')
         if cont_name == 'groups' and self.request.params.get('propagate') =='true':
             self._propagate_permissions(cont_name, _id, query={'permissions._id' : payload['_id']}, update={'$set': {'permissions.$.access': payload['access']}})
+            self._propagate_permissions(cont_name, _id, query={'permissions._id': {'$ne': payload['_id']}}, update={'$addToSet': {'permissions': payload}})
         elif cont_name != 'groups':
             self._propagate_permissions(cont_name, _id)
         return result
-- 
GitLab