Unused argument 'kwargs'
207 if channel.provider == 'bbb':
208 create_bbb_meeting(channel, data)
209
210 def before_post(self, args, kwargs, data):211 self.validate(data)
212 self.setup_channel(data)
213
Unused argument 'args'
207 if channel.provider == 'bbb':
208 create_bbb_meeting(channel, data)
209
210 def before_post(self, args, kwargs, data):211 self.validate(data)
212 self.setup_channel(data)
213
Unused argument 'args'
36
37
38class VideoChannelDetail(ResourceDetail):
39 def before_get(self, args, kwargs):40 if is_logged_in() and has_access('is_admin'):
41 self.schema = VideoChannelSchema
42 else:
Unused argument 'args'
21
22
23class VideoChannelList(ResourceList):
24 def before_get(self, args, kwargs):25 if is_logged_in() and has_access('is_admin'):
26 self.schema = VideoChannelSchema
27 else:
Unused argument 'kwargs'
21
22
23class VideoChannelList(ResourceList):
24 def before_get(self, args, kwargs):25 if is_logged_in() and has_access('is_admin'):
26 self.schema = VideoChannelSchema
27 else:
Unused argument 'args'
117 User detail by id
118 """
119
120 def before_get(self, args, kwargs):121 if current_user.is_admin or current_user.is_super_admin or current_user:
122 self.schema = UserSchema
123 else:
Unused argument 'kwargs'
117 User detail by id
118 """
119
120 def before_get(self, args, kwargs):121 if current_user.is_admin or current_user.is_super_admin or current_user:
122 self.schema = UserSchema
123 else:
Unused argument 'args'
128 List Tickets based on different params
129 """
130
131 def before_get(self, args, view_kwargs):132 """
133 before get method to get the resource id for assigning schema
134 :param args:
Unused argument 'args'
219 Ticket Resource
220 """
221
222 def before_get(self, args, view_kwargs):223 """
224 before get method to get the resource id for assigning schema
225 :param args:
Unused argument 'args'
59 "Tax already exists for this event",
60 )
61
62 def before_get(self, args, kwargs): 63 """
64 method to assign proper schema based on admin access
65 :param args:
Unused argument 'kwargs'
59 "Tax already exists for this event",
60 )
61
62 def before_get(self, args, kwargs): 63 """
64 method to assign proper schema based on admin access
65 :param args:
Unused argument 'args'
108 Stripe Authorization Detail Resource by ID
109 """
110
111 def before_get(self, args, kwargs):112 """
113 method for assigning schema based on access
114 :param args:
Unused argument 'args'
13 List and Create Social Links for an event
14 """
15
16 def before_post(self, args, kwargs, data):17 """
18 before post method to check for required relationship and proper permission
19 :param args:
Unused argument 'kwargs'
13 List and Create Social Links for an event
14 """
15
16 def before_post(self, args, kwargs, data):17 """
18 before post method to check for required relationship and proper permission
19 :param args:
Unused argument 'kwargs'
152 OrderListPost class for OrderSchema
153 """
154
155 def before_post(self, args, kwargs, data=None):156 """
157 before post method to check for required relationships and permissions
158 :param args:
Unused argument 'args'
152 OrderListPost class for OrderSchema
153 """
154
155 def before_post(self, args, kwargs, data=None):156 """
157 before post method to check for required relationships and permissions
158 :param args:
Unused argument 'args'
505 if not is_logged_in() or not has_access('is_coorganizer', event_id=event.id):
506 raise ObjectNotFound({'parameter': '{id}'}, "Event: not found")
507
508 def before_patch(self, args, kwargs, data=None):509 """
510 before patch method to verify if the event location is provided before publishing the event and checks that
511 the user is verified
Unused argument 'args'
479 EventDetail class for EventSchema
480 """
481
482 def before_get(self, args, kwargs):483 """
484 method for assigning schema based on access
485 :param args:
Unused argument 'args'
357
358 return query_
359
360 def before_post(self, args, kwargs, data=None):361 """
362 before post method to verify if the event location is provided before publishing the event
363 and checks that the user is verified
Unused argument 'args'
190
191
192class EventList(ResourceList):
193 def before_get(self, args, kwargs):194 """
195 method for assigning schema based on admin access
196 :param args:
Unused argument 'kwargs'
505 if not is_logged_in() or not has_access('is_coorganizer', event_id=event.id):
506 raise ObjectNotFound({'parameter': '{id}'}, "Event: not found")
507
508 def before_patch(self, args, kwargs, data=None):509 """
510 before patch method to verify if the event location is provided before publishing the event and checks that
511 the user is verified
Unused argument 'args'
221 elif used_for == 'event':
222 self.schema = DiscountCodeSchemaEvent
223
224 def before_get(self, args, kwargs):225 if kwargs.get('ticket_id'):
226 if has_access('is_coorganizer'):
227 ticket = safe_query_kwargs(Ticket, kwargs, 'ticket_id')
Unused argument 'args'
119 AccessCode detail by id or code
120 """
121
122 def before_get(self, args, kwargs):123 """
124 before get method of access code details.
125 Check for permissions on the basis of kwargs.
Description
An unused argument can lead to confusions. It should be removed. If this variable is necessary, name the variable _
or start the name with unused
or _unused
.
Bad practice
def square(x, y=1):
return x * x
class MySubClass(MyClass):
def __init__(self, number):
self.value = 42 # argument `number` remains unused
Preferred:
def square(x):
return x * x
class MySubClass(MyClass):
def __init__(self, _):
self.value = 42