mirror of
https://github.com/docusealco/docuseal
synced 2026-11-06 06:52:33 -05:00
validate sender email
This commit is contained in:
1 parent
49cea59b94
commit
bbe3942056
3 files changed
+25
-2
No files matched your search
@@ -0,0 +1,15 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
module Submitters
|
||||
module ValidateSending
|
||||
InvalidEmail = Class.new(StandardError)
|
||||
|
||||
module_function
|
||||
|
||||
def call(submitter, _mail)
|
||||
raise InvalidEmail unless submitter.email.to_s.include?('@')
|
||||
|
||||
true
|
||||
end
|
||||
end
|
||||
end
|
||||
Reference in new issue
Block a user