mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-08-29 12:09:20 +03:00
Use SNAPPYMAIL_INCLUDE_AS_API and added SSO test
This commit is contained in:
parent
dd6779b1a8
commit
7f084dda53
4 changed files with 29 additions and 8 deletions
|
|
@ -65,12 +65,12 @@ class SnappyMailHelper {
|
|||
{
|
||||
self::regSnappyMailDataFunction();
|
||||
|
||||
$_ENV['RAINLOOP_INCLUDE_AS_API'] = true;
|
||||
$_ENV['SNAPPYMAIL_INCLUDE_AS_API'] = true;
|
||||
include $sPath;
|
||||
|
||||
if (class_exists('\\SnappyMail\\Api'))
|
||||
if (class_exists('\\RainLoop\\Api'))
|
||||
{
|
||||
$SsoHash = \SnappyMail\Api::GetUserSsoHash($sEmail, $sPassword);
|
||||
$SsoHash = \RainLoop\Api::GetUserSsoHash($sEmail, $sPassword);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -238,10 +238,10 @@ class SnappyMailHelper {
|
|||
|
||||
self::regSnappyMailDataFunction();
|
||||
|
||||
$_ENV['RAINLOOP_INCLUDE_AS_API'] = true;
|
||||
$_ENV['SNAPPYMAIL_INCLUDE_AS_API'] = true;
|
||||
include $sApiPath;
|
||||
|
||||
\SnappyMail\Api::LogoutCurrentLogginedUser();
|
||||
\RainLoop\Api::LogoutCurrentLogginedUser();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue