update api and ajax handling and response
This commit is contained in:
@@ -273,7 +273,7 @@ class EmailAccounts extends \Froxlor\Api\ApiCommand implements \Froxlor\Api\Reso
|
||||
$result = $this->apiCall('Emails.get', array(
|
||||
'emailaddr' => $result['email_full']
|
||||
));
|
||||
return $this->response(200, "successful", $result);
|
||||
return $this->response($result);
|
||||
}
|
||||
throw new \Exception("No more resources available", 406);
|
||||
}
|
||||
@@ -404,7 +404,7 @@ class EmailAccounts extends \Froxlor\Api\ApiCommand implements \Froxlor\Api\Reso
|
||||
$result = $this->apiCall('Emails.get', array(
|
||||
'emailaddr' => $result['email_full']
|
||||
));
|
||||
return $this->response(200, "successful", $result);
|
||||
return $this->response($result);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -507,6 +507,6 @@ class EmailAccounts extends \Froxlor\Api\ApiCommand implements \Froxlor\Api\Reso
|
||||
Customers::decreaseUsage($customer['customerid'], 'email_quota_used', '', $quota);
|
||||
|
||||
$this->logger()->logAction($this->isAdmin() ? \Froxlor\FroxlorLogger::ADM_ACTION : \Froxlor\FroxlorLogger::USR_ACTION, LOG_INFO, "[API] deleted email account for '" . $result['email_full'] . "'");
|
||||
return $this->response(200, "successful", $result);
|
||||
return $this->response($result);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user