Reformatted Link Command
This commit is contained in:
@@ -1,6 +1,7 @@
|
|||||||
# 1.0.9
|
# 1.0.9
|
||||||
|
|
||||||
- You can now configure trial account duration
|
- You can now configure trial account duration
|
||||||
|
- Reformatted link command
|
||||||
|
|
||||||
# 1.0.8
|
# 1.0.8
|
||||||
|
|
||||||
|
|||||||
@@ -56,7 +56,7 @@ Fill out values in the .env and you're good to go!
|
|||||||
|
|
||||||
***🛠️ Admin Commands***
|
***🛠️ Admin Commands***
|
||||||
|
|
||||||
- `!link` <jellyfin_username> @user - Manually link accounts
|
- `!link` @user <jellyfin_username> - Manually link accounts
|
||||||
- `!unlink` @user - Manually unlink accounts
|
- `!unlink` @user - Manually unlink accounts
|
||||||
- `!validusers` - Show number of valid and invalid accounts
|
- `!validusers` - Show number of valid and invalid accounts
|
||||||
- `!cleanup` - Remove Jellyfin accounts from users without roles
|
- `!cleanup` - Remove Jellyfin accounts from users without roles
|
||||||
|
|||||||
10
app.py
10
app.py
@@ -1597,9 +1597,9 @@ async def storage(ctx):
|
|||||||
|
|
||||||
|
|
||||||
@bot.command()
|
@bot.command()
|
||||||
async def link(ctx, jellyfin_username: str = None, user: discord.User = None, js_id: str = None):
|
async def link(ctx, user: discord.User = None, jellyfin_username: str = None, js_id: str = None):
|
||||||
log_event(f"link invoked by {ctx.author}")
|
log_event(f"link invoked by {ctx.author}")
|
||||||
usage_args = ["<Jellyfin Account>", "<@user>"]
|
usage_args = ["<@user>", "<Jellyfin Account>"]
|
||||||
if JELLYSEERR_ENABLED: usage_args.append("<Jellyseerr ID>")
|
if JELLYSEERR_ENABLED: usage_args.append("<Jellyseerr ID>")
|
||||||
|
|
||||||
if jellyfin_username is None or user is None or (JELLYSEERR_ENABLED and js_id is None):
|
if jellyfin_username is None or user is None or (JELLYSEERR_ENABLED and js_id is None):
|
||||||
@@ -1617,7 +1617,7 @@ async def link(ctx, jellyfin_username: str = None, user: discord.User = None, js
|
|||||||
return
|
return
|
||||||
|
|
||||||
add_account(user.id, jellyfin_username, jf_id, js_id)
|
add_account(user.id, jellyfin_username, jf_id, js_id)
|
||||||
await ctx.send(f"✅ Linked Jellyfin account **{jellyfin_username}** to {user.mention}.")
|
await ctx.send(f"✅ Linked {user.mention} to Jellyfin account **{jellyfin_username}**.")
|
||||||
|
|
||||||
|
|
||||||
@bot.command()
|
@bot.command()
|
||||||
@@ -1805,9 +1805,9 @@ async def help_command(ctx):
|
|||||||
# --- Admin Commands ---
|
# --- Admin Commands ---
|
||||||
if is_admin:
|
if is_admin:
|
||||||
# Admin Jellyfin commands
|
# Admin Jellyfin commands
|
||||||
link_command = f"`{PREFIX}link <jellyfin_username> @user` - Manually link accounts"
|
link_command = f"`{PREFIX}link @user <jellyfin_username>` - Manually link accounts"
|
||||||
if JELLYSEERR_ENABLED:
|
if JELLYSEERR_ENABLED:
|
||||||
link_command = f"`{PREFIX}link <jellyfin_username> @user <Jellyseerr ID>` - Link accounts with Jellyseerr"
|
link_command = f"`{PREFIX}link @user <jellyfin_username> <Jellyseerr ID>` - Link accounts with Jellyseerr"
|
||||||
|
|
||||||
admin_cmds = [
|
admin_cmds = [
|
||||||
link_command,
|
link_command,
|
||||||
|
|||||||
Reference in New Issue
Block a user