It's Riseup's twentieth year, help keep us going! If you can afford it, please contribute to our winter fundraising drive.

Commit afdca4c8 authored by ng's avatar ng

Merge branch 'paz/argument-refresh-keys' into 'master'

Show error if list for `refresh_keys` does not exist.

See merge request !296
parents ce5c8d07 cd2e2553
Pipeline #26845 passed with stages
in 21 minutes and 42 seconds
......@@ -8,6 +8,7 @@ This project adheres to [Semantic Versioning](
### Fixed
* Do not crash on protected header emails generated by mutt (#430)
* Show an error message if `refresh_keys` is called with an email address for which no list exists.
### Changed
......@@ -320,10 +320,13 @@ Please notify the users and admins of this list of these changes.
def work_on_lists(subj, list=nil)
selected_lists = if list.nil?
if list.nil?
selected_lists = List.all
List.where(email: list)
selected_lists = List.where(email: list)
if selected_lists.blank?
error("No list with this address exists: #{list.inspect}")
selected_lists.each do |list|
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment