refactor: replace custom CRM with Monica fork
Some checks failed
Build & Push Monica Image to Gitea Registry / build-and-push (push) Failing after 9s

This commit is contained in:
Kroonk
2026-05-22 16:19:55 +02:00
parent 38cc4c09ca
commit a213a1dba0
2215 changed files with 242567 additions and 6015 deletions

View File

@@ -0,0 +1,44 @@
<?php
namespace App\Services\DavClient\Utils\Model;
use function Safe\fclose;
use function Safe\stream_get_contents;
class ContactUpdateDto extends ContactDto
{
/**
* @var string
*/
public $card;
/**
* Create a new ContactUpdateDto.
*
* @param string $uri
* @param string|null $etag
* @param string|resource $card
*/
public function __construct(string $uri, ?string $etag, $card)
{
parent::__construct($uri, $etag);
$this->card = self::transformCard($card);
}
/**
* Transform card.
*
* @param string|resource $card
* @return string
*/
protected static function transformCard($card): string
{
if (is_resource($card)) {
$card = tap(stream_get_contents($card), function () use ($card) {
fclose($card);
});
}
return $card;
}
}