مراية لـ
https://github.com/postalserver/postal.git
تم المزامنة 2026-04-21 06:08:09 +00:00
style(rubocop): Style/FrozenStringLiteralComment
هذا الالتزام موجود في:
@@ -1,2 +1,3 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
end
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
require "logger"
|
||||
|
||||
module Postal
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
class BounceMessage
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
require "erb"
|
||||
require "yaml"
|
||||
require "pathname"
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module Countries
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
class DKIMHeader
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
|
||||
module Errors
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module Helpers
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
require "net/https"
|
||||
require "uri"
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
class HTTPSender < Sender
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
require "nifty/utils/random_string"
|
||||
|
||||
module Postal
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
end
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
class Click
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
class ConnectionPool
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
class Database
|
||||
@@ -144,7 +145,7 @@ module Postal
|
||||
# :count => Return a count of the results instead of the actual data
|
||||
#
|
||||
def select(table, options = {})
|
||||
sql_query = "SELECT"
|
||||
sql_query = String.new("SELECT")
|
||||
if options[:count]
|
||||
sql_query << " COUNT(id) AS count"
|
||||
elsif options[:fields]
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
class Delivery
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
class LiveStats
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
class Load
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
class Message
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
class Migration
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
module Migrations
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
module Migrations
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
module Migrations
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
module Migrations
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
module Migrations
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
module Migrations
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
module Migrations
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
module Migrations
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
module Migrations
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
module Migrations
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
module Migrations
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
module Migrations
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
module Migrations
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
module Migrations
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
module Migrations
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
module Migrations
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
module Migrations
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
module Migrations
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
module Migrations
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
module Migrations
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
class Provisioner
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
class Statistics
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
class SuppressionList
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageDB
|
||||
class Webhooks
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
class MessageInspection
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
class MessageInspector
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageInspectors
|
||||
end
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageInspectors
|
||||
class Clamav < MessageInspector
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
require "net/http"
|
||||
|
||||
module Postal
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module MessageInspectors
|
||||
class SpamAssassin < MessageInspector
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
class MessageParser
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
class MessageRequeuer
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
class MXLookup
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
class QueryString
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
require "postal/config"
|
||||
require "bunny"
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
class ReceivedHeader
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
class ReplySeparator
|
||||
|
||||
@@ -19,7 +20,7 @@ module Postal
|
||||
return "" unless text.is_a?(String)
|
||||
|
||||
text = text.gsub("\r", "")
|
||||
stripped = ""
|
||||
stripped = String.new
|
||||
RULES.each do |rule|
|
||||
text.gsub!(rule) do
|
||||
stripped = ::Regexp.last_match(0).to_s + "\n" + stripped
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module RspecHelpers
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
class SendResult
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
class Sender
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
require "resolv"
|
||||
|
||||
module Postal
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
module SMTPServer
|
||||
end
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
require "resolv"
|
||||
require "nifty/utils/random_string"
|
||||
|
||||
@@ -360,7 +361,7 @@ module Postal
|
||||
return "503 HELO/EHLO, MAIL FROM and RCPT TO before sending data"
|
||||
end
|
||||
|
||||
@data = "".force_encoding("BINARY")
|
||||
@data = String.new.force_encoding("BINARY")
|
||||
@headers = {}
|
||||
@receiving_headers = true
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
require "ipaddr"
|
||||
require "nio"
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
class SpamCheck
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
class TrackingMiddleware
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
require "highline"
|
||||
|
||||
module Postal
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
|
||||
VERSION_PATH = File.expand_path("../../VERSION", __dir__)
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
module Postal
|
||||
class Worker
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
# NOTE: only doing this in development as some production environments (Heroku)
|
||||
# NOTE: are sensitive to local FS writes, and besides -- it's just not proper
|
||||
# NOTE: to have a dev-mode tool do its thing in production.
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
# frozen_string_literal: true
|
||||
namespace :postal do
|
||||
desc "Start the cron worker"
|
||||
task cron: :environment do
|
||||
|
||||
المرجع في مشكلة جديدة
حظر مستخدم