File tree 1 file changed +4
-9
lines changed 1 file changed +4
-9
lines changed Original file line number Diff line number Diff line change @@ -167,25 +167,20 @@ def print_submission_result(submission): # used python-leetocde library
167
167
def initialize_leetcode_api_instance (
168
168
leetcode_session , leetcode_csrf_token
169
169
): # used python-leetocde library
170
- configuration = leetcode \
171
- .Configuration ()
170
+ configuration = leetcode .Configuration ()
172
171
csrf_token = leetcode_csrf_token
173
-
174
172
configuration .api_key ["x-csrftoken" ] = csrf_token
175
173
configuration .api_key ["csrftoken" ] = csrf_token
176
174
configuration .api_key ["LEETCODE_SESSION" ] = leetcode_session
177
- configuration .api_key ["Referer" ] = "https://leetcode .com"
175
+ configuration .api_key ["Referer" ] = "https://.com"
178
176
configuration .debug = False
179
177
180
- api_instance = leetcode \
181
- .DefaultApi (leetcode
182
- .ApiClient (configuration ))
178
+ api_instance = .DefaultApi (.ApiClient (configuration ))
183
179
return api_instance
184
180
185
181
186
182
def interpret_solution (title_slug , payload , api_instance ):
187
- test_submission = leetcode \
188
- .TestSubmission (
183
+ test_submission = .TestSubmission (
189
184
data_input = payload ["data_input" ],
190
185
typed_code = payload ["typed_code" ],
191
186
question_id = payload ["question_id" ],
You can’t perform that action at this time.
0 commit comments