Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -176,7 +176,8 @@ async def optimize_and_upload(images_urls: list[str] | str, convert: bool = Fals
|
|
176 |
from aiorentry.client import Client as RentryClient
|
177 |
async with RentryClient('https://rentry.org') as client:
|
178 |
page = await client.new_page(content)
|
179 |
-
|
|
|
180 |
except Exception as e:
|
181 |
print(f'не удалось создать страницу в rentry: {e}')
|
182 |
return new_images_urls
|
|
|
176 |
from aiorentry.client import Client as RentryClient
|
177 |
async with RentryClient('https://rentry.org') as client:
|
178 |
page = await client.new_page(content)
|
179 |
+
page_id = page.url
|
180 |
+
return [f'https://rentry.co/{page_id}', f'https://rentry.org/{page_id}']
|
181 |
except Exception as e:
|
182 |
print(f'не удалось создать страницу в rentry: {e}')
|
183 |
return new_images_urls
|