Skip to content

Commit

Permalink
Adds getattr to permission_set_ids on the permission_set issue (#9)
Browse files Browse the repository at this point in the history
  • Loading branch information
vmesel authored Dec 18, 2023
1 parent 224f574 commit 93d9823
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion target_salesforce_v3/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -371,7 +371,7 @@ def add_custom_field(self,cf,label=None):
# But then, we need to add the permissions to the Task sObject
# So we change it back again from `Activity` -> `Task`
sobject = 'Task'
for permission_set_id in self.permission_set_ids:
for permission_set_id in getattr(self, "permission_set_ids", []):
self.update_field_permissions(permission_set_id, sobject_type=sobject, field_name=f"{sobject}.{cf}")

def update_field_permissions(self,permission_set_id, sobject_type, field_name):
Expand Down

0 comments on commit 93d9823

Please sign in to comment.