You cannot call super when using classeval because you are overwriting it. A working solution is to use aliasmethod and to replace super.
... aliasmethod :oldmail, :mail ... old_mail(headers, &block)
You cannot call super when using classeval because you are overwriting it. A working solution is to use aliasmethod and to replace super.
...
aliasmethod :oldmail, :mail
...
old_mail(headers, &block)