forked from rDrama/rDrama
fds
parent
fdcdb3b652
commit
ca93bcd11f
|
@ -27,7 +27,10 @@ month = datetime.now().strftime('%B')
|
||||||
@app.get('/fix')
|
@app.get('/fix')
|
||||||
@admin_level_required(3)
|
@admin_level_required(3)
|
||||||
def fix(v):
|
def fix(v):
|
||||||
for post in g.db.query(Submission).filter(Submission.url.like('https://i.ibb.co/%.webp')):
|
li = g.db.query(Submission).filter(Submission.url.like('https://i.ibb.co/%.webp')).all()
|
||||||
|
num = request.values.get('num')
|
||||||
|
if num: li = li[:num]
|
||||||
|
for post in li:
|
||||||
print(post.id, flush=True)
|
print(post.id, flush=True)
|
||||||
req = requests.get(f"https://web.archive.org/{post.url}", timeout=5)
|
req = requests.get(f"https://web.archive.org/{post.url}", timeout=5)
|
||||||
if str(req) == '<Response [200]>':
|
if str(req) == '<Response [200]>':
|
||||||
|
|
Loading…
Reference in New Issue