HomeHelpTrac

Ignore:
Timestamp:
07/27/11 23:30:27 (10 months ago)
Author:
Alexander Trofimov
Message:

Ticket #2580

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/xmlrpc/BxDolXMLRPCImages.php

    r15211 r15396  
    3636        if (!$iIdProfile || !($iId = BxDolXMLRPCUtil::checkLogin ($sUser, $sPwd))) 
    3737            return new xmlrpcresp(new xmlrpcval(array('error' => new xmlrpcval(1,"int")), "struct")); 
     38 
     39        // create user's default album if there is no one 
     40        if ($sUser == $sNick) { 
     41            $sCaption = str_replace('{nickname}', $sUser, getParam('bx_photos_profile_album_name')); 
     42            bx_import('BxDolAlbums'); 
     43            $oAlbum = new BxDolAlbums('bx_photos'); 
     44            $aData = array( 
     45                'caption' => $sCaption, 
     46                'location' => _t('_bx_photos_undefined'), 
     47                'owner' => $iId, 
     48                'AllowAlbumView' => BX_DOL_PG_ALL, 
     49            ); 
     50            $oAlbum->addAlbum($aData); 
     51        }  
    3852 
    3953        return BxDolXMLRPCMedia::_getMediaAlbums ('photo', $iIdProfile, $iId, $iIdProfile == $iId); 
Note: See TracChangeset for help on using the changeset viewer.