File tree Expand file tree Collapse file tree 1 file changed +3
-4
lines changed Expand file tree Collapse file tree 1 file changed +3
-4
lines changed Original file line number Diff line number Diff line change @@ -128,8 +128,7 @@ def repo_text(update, context):
128
128
try :
129
129
repo = context .chat_data ['repos' ][int (context .match .group (1 ))]
130
130
except KeyError :
131
- # TODO: Allow two actions for a button: both deleting and going back
132
- return 'Repository deleted successfully.'
131
+ return 'Repository removed successfully.'
133
132
134
133
return f'Menu for { repo .name } '
135
134
@@ -142,15 +141,15 @@ def repo_buttons(update, context):
142
141
143
142
return [
144
143
[ToggleButton ('enabled' , value = repo .enabled , text = 'Enabled' )],
145
- [SetButton ('delete ' , None , 'Delete ' )], # TODO: "Delete" sounds wayyyy too destructive
144
+ [SetButton ('remove ' , None , 'Remove ' )],
146
145
[BackButton ('Back' )]
147
146
]
148
147
149
148
150
149
def repo_set_data (update , context ):
151
150
repo_id = int (context .match .group (1 ))
152
151
153
- if context .key == 'delete ' :
152
+ if context .key == 'remove ' :
154
153
del context .chat_data ['repos' ][repo_id ]
155
154
else :
156
155
repo = context .chat_data ['repos' ][repo_id ]
You can’t perform that action at this time.
0 commit comments