Пример #1
0
 public static function save_card($inbound, $outbound)
 {
     Util::keys_required($inbound, array('id'));
     $stack = new Stack(Util::safe_stack_id($inbound['id']), Util::optional($inbound, 'auth_hash'));
     if (array_key_exists('card', $inbound)) {
         $stack->stack_save_card($inbound['card']);
     }
     if (array_key_exists('bkgnd', $inbound)) {
         $stack->stack_save_bkgnd($inbound['bkgnd']);
     }
     return $outbound;
 }
Пример #2
0
 public static function save_card($inbound, $outbound)
 {
     $stack = new Stack(Util::safe_stack_id($inbound['stack_id']));
     $stack->stack_save_card($inbound['card']);
     //throw new ('Temporary error');
     return $outbound;
 }