DmitrMakeev commited on
Commit
809a236
·
verified ·
1 Parent(s): 98827d4

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +0 -22
app.py CHANGED
@@ -226,28 +226,6 @@ def initialize_requests():
226
 
227
 
228
 
229
- # Хранилище для кода
230
- code_storage = {}
231
-
232
- def execute_code(update: Update, context: CallbackContext) -> None:
233
- command = update.message.text.split()[0]
234
- if command in code_storage:
235
- exec(code_storage[command])
236
-
237
- @app.route('/webhook', methods=['POST'])
238
- def webhook():
239
- update = Update.de_json(request.get_json(force=True), bot)
240
- dispatcher.process_update(update)
241
- return jsonify(ok=True)
242
-
243
- @app.route('/execute', methods=['POST'])
244
- def execute():
245
- data = request.json
246
- command = data['command']
247
- code = data['code']
248
- code_storage[command] = code
249
- return jsonify(ok=True)
250
-
251
 
252
 
253
 
 
226
 
227
 
228
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
229
 
230
 
231