public function donate(User $recipient, $amount){
$mysidia = Registry::get("mysidia");
// First thing first, let's update the money field for the two users
$this->changecash(-$amount);
$recipient->changecash($amount);
// Then attempt to send an email to the recipient
$recipient->getoptions();
if($recipient->options->newmessagenotify == 1){
// We are sending this user an email about the donation
$headers = "From: {$mysidia->settings->systememail}";
$sitename = $mysidia->settings->sitename;
$message = "Hello {$recipient->username};\n\nYou have received {$amount} {$mysidia->settings->cost} donation from {$this->username} at {$sitename}.
Thank You. The {$siteName} team.";
mail($recipient->email, $sitename." - You Have Received a {$mysidia->settings->cost} Donation", $message, $headers);
}
}