مراية لـ
https://github.com/postalserver/postal.git
تم المزامنة 2025-12-01 05:43:04 +00:00
style(rubocop): Style/WordArray
هذا الالتزام موجود في:
@@ -160,7 +160,7 @@ module Postal
|
||||
end
|
||||
if options[:order]
|
||||
direction = (options[:direction] || "ASC").upcase
|
||||
raise Postal::Error, "Invalid direction #{options[:direction]}" unless ["ASC", "DESC"].include?(direction)
|
||||
raise Postal::Error, "Invalid direction #{options[:direction]}" unless %w[ASC DESC].include?(direction)
|
||||
|
||||
sql_query << " ORDER BY `#{options[:order]}` #{direction}"
|
||||
end
|
||||
|
||||
@@ -70,9 +70,9 @@ module Postal
|
||||
# environment and can be quite dangerous in production.
|
||||
#
|
||||
def clean
|
||||
["clicks", "deliveries", "links", "live_stats", "loads", "messages",
|
||||
"raw_message_sizes", "spam_checks", "stats_daily", "stats_hourly",
|
||||
"stats_monthly", "stats_yearly", "suppressions", "webhook_requests"].each do |table|
|
||||
%w[clicks deliveries links live_stats loads messages
|
||||
raw_message_sizes spam_checks stats_daily stats_hourly
|
||||
stats_monthly stats_yearly suppressions webhook_requests].each do |table|
|
||||
@database.query("TRUNCATE `#{@database.database_name}`.`#{table}`")
|
||||
end
|
||||
end
|
||||
|
||||
المرجع في مشكلة جديدة
حظر مستخدم