mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-06-27 00:36:44 +03:00
No need to respond APP_VERSION in FolderInformation and FolderInformationMultiply requests
This commit is contained in:
parent
e4149b655c
commit
06cb57bc93
3 changed files with 5 additions and 9 deletions
|
|
@ -551,9 +551,9 @@ class AppUser extends AbstractApp {
|
|||
const folders = FolderUserStore.getNextFolderNames(refreshFolders);
|
||||
if (arrayLength(folders)) {
|
||||
Remote.folderInformationMultiply((iError, oData) => {
|
||||
if (!iError && arrayLength(oData.Result.List)) {
|
||||
if (!iError && arrayLength(oData.Result)) {
|
||||
const utc = Date.now();
|
||||
oData.Result.List.forEach(item => {
|
||||
oData.Result.forEach(item => {
|
||||
const hash = getFolderHash(item.Folder),
|
||||
folder = getFolderFromCacheList(item.Folder);
|
||||
|
||||
|
|
|
|||
|
|
@ -386,8 +386,6 @@ trait Folders
|
|||
throw new ClientException(Notifications::MailServerError, $oException);
|
||||
}
|
||||
|
||||
$aInboxInformation['Version'] = APP_VERSION;
|
||||
|
||||
return $this->DefaultResponse(__FUNCTION__, $aInboxInformation);
|
||||
}
|
||||
|
||||
|
|
@ -396,10 +394,7 @@ trait Folders
|
|||
*/
|
||||
public function DoFolderInformationMultiply() : array
|
||||
{
|
||||
$aResult = array(
|
||||
'List' => array(),
|
||||
'Version' => APP_VERSION
|
||||
);
|
||||
$aResult = array();
|
||||
|
||||
$aFolders = $this->GetActionParam('Folders', null);
|
||||
if (\is_array($aFolders))
|
||||
|
|
@ -416,7 +411,7 @@ trait Folders
|
|||
$aInboxInformation = $this->MailClient()->FolderInformation($sFolder);
|
||||
if (isset($aInboxInformation['Folder']))
|
||||
{
|
||||
$aResult['List'][] = [
|
||||
$aResult[] = [
|
||||
'Folder' => $aInboxInformation['Folder'],
|
||||
'Hash' => $aInboxInformation['Hash'],
|
||||
'MessageCount' => $aInboxInformation['MessageCount'],
|
||||
|
|
|
|||
|
|
@ -100,6 +100,7 @@ trait Response
|
|||
$sActionName = \preg_replace('/[^a-zA-Z0-9_]+/', '', $sActionName);
|
||||
|
||||
$aResult = array(
|
||||
// 'Version' => APP_VERSION,
|
||||
'Action' => $sActionName,
|
||||
'Result' => $this->responseObject($mResult, $sActionName)
|
||||
);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue