utils.github_webhook: _format_star(): return count of star and forks only, do not include the time starred at
This commit is contained in:
@@ -170,10 +170,7 @@ async def _format_push(payload: dict) -> str:
|
|||||||
|
|
||||||
|
|
||||||
async def _format_star(payload: dict) -> str:
|
async def _format_star(payload: dict) -> str:
|
||||||
time = payload['starred_at']
|
return await _get_repo_star_and_fork(payload['repository'])
|
||||||
text = [f"\u2192 starred at <code>{time}</code>"] if time else []
|
|
||||||
text.append(await _get_repo_star_and_fork(payload['repository']))
|
|
||||||
return "\n".join(text)
|
|
||||||
|
|
||||||
|
|
||||||
async def _get_event_title(event: str, payload: dict) -> str:
|
async def _get_event_title(event: str, payload: dict) -> str:
|
||||||
|
|||||||
Reference in New Issue
Block a user