Skip to content

Commit

Permalink
fix build error - characters too long in 1 line
Browse files Browse the repository at this point in the history
  • Loading branch information
sidgupta committed Apr 10, 2016
1 parent c1c31c3 commit f962522
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions caravel/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -556,10 +556,12 @@ def save_or_overwrite_slice(self, args, slc):
slc.table_id = table_id
slc.datasource_type = datasource_type
slc.slice_name = slice_name
user_slice_add_perm = self.appbuilder.sm.has_access('can_add', 'SliceModelView')
user_slice_edit_perm = self.appbuilder.sm.has_access('can_edit', 'SliceModelView')

if action == 'save' and self.appbuilder.sm.has_access('can_add', 'SliceModelView'):
if action == 'save' and user_slice_add_perm:
self.save_slice(slc)
elif action == 'overwrite' and self.appbuilder.sm.has_access('can_edit', 'SliceModelView'):
elif action == 'overwrite' and user_slice_edit_perm:
self.overwrite_slice(slc)

return redirect(slc.slice_url)
Expand Down

0 comments on commit f962522

Please sign in to comment.