<?php

namespace RtmMail\Actions\Handlers;

class TestMailAction
{
    public function handleAction(): array
    {
        $result = wp_mail(get_option('admin_email'), 'Test Email Subject', '<p>This is a test email body.</p>', ['Content-Type: text/html; charset=UTF-8']);
        if ($result == true){
            return [ 'success' => true ];
        }
        return [ 'success' => false ];
    }
}
