No need to make the properties readonly

This commit is contained in:
Daniil Gentili 2024-04-19 23:31:39 +02:00
parent 5f15cf9130
commit 5b1b69369e
7 changed files with 29 additions and 29 deletions

View File

@ -41,64 +41,64 @@ final class FileId
* DC ID.
*
*/
public readonly int $dcId,
public int $dcId,
/**
* File type.
*
*/
public readonly FileIdType $type,
public FileIdType $type,
/**
* File id.
*
*/
public readonly ?int $id,
public ?int $id,
/**
* File access hash.
*
*/
public readonly int $accessHash,
public int $accessHash,
/**
* Photo size source.
*
*/
public readonly ?PhotoSizeSource $photoSizeSource = null,
public ?PhotoSizeSource $photoSizeSource = null,
/**
* Photo volume ID.
*
*/
public readonly ?int $volumeId = null,
public ?int $volumeId = null,
/**
* Photo local ID.
*
*/
public readonly ?int $localId = null,
public ?int $localId = null,
/**
* File reference.
*
*/
public readonly ?string $fileReference = null,
public ?string $fileReference = null,
/**
* File URL for weblocation.
*
*/
public readonly ?string $url = null,
public ?string $url = null,
/**
* Bot API file ID version.
*
*/
public readonly int $version = 4,
public int $version = 4,
/**
* Bot API file ID subversion.
*
*/
public readonly int $subVersion = 47,
public int $subVersion = 47,
) {
}

View File

@ -28,8 +28,8 @@ use danog\Decoder\PhotoSizeSource;
abstract class PhotoSizeSourceDialogPhoto extends PhotoSizeSource
{
public function __construct(
public readonly int $dialogId,
public readonly int $dialogAccessHash,
public int $dialogId,
public int $dialogAccessHash,
) {
}
/**

View File

@ -28,7 +28,7 @@ use danog\Decoder\PhotoSizeSource;
final class PhotoSizeSourceLegacy extends PhotoSizeSource
{
public function __construct(
public readonly int $secret,
public int $secret,
) {
}
}

View File

@ -32,12 +32,12 @@ final class PhotoSizeSourceStickersetThumbnail extends PhotoSizeSource
* Stickerset ID.
*
*/
public readonly int $stickerSetId,
public int $stickerSetId,
/**
* Stickerset access hash.
*
*/
public readonly int $stickerSetAccessHash
public int $stickerSetAccessHash
) {
}

View File

@ -32,17 +32,17 @@ final class PhotoSizeSourceStickersetThumbnailVersion extends PhotoSizeSource
* Stickerset ID.
*
*/
public readonly int $stickerSetId,
public int $stickerSetId,
/**
* Stickerset access hash.
*
*/
public readonly int $stickerSetAccessHash,
public int $stickerSetAccessHash,
/**
* Stickerset version.
*
*/
public readonly int $stickerSetVersion
public int $stickerSetVersion
) {
}

View File

@ -33,12 +33,12 @@ final class PhotoSizeSourceThumbnail extends PhotoSizeSource
* File type of original file.
*
*/
public readonly FileIdType $thumbFileType,
public FileIdType $thumbFileType,
/**
* Thumbnail size.
*
*/
public readonly string $thumbType,
public string $thumbType,
) {
}
}

View File

@ -37,42 +37,42 @@ final class UniqueFileId
* File type.
*
*/
public readonly UniqueFileIdType $type,
public UniqueFileIdType $type,
/**
* File ID.
*
*/
public readonly ?int $id = null,
public ?int $id = null,
/**
* Photo subtype.
*
*/
public readonly ?int $subType = null,
public ?int $subType = null,
/**
* Photo volume ID.
*
*/
public readonly ?int $volumeId = null,
public ?int $volumeId = null,
/**
* Photo local ID.
*
*/
public readonly ?int $localId = null,
public ?int $localId = null,
/**
* Sticker set ID.
*
*/
public readonly ?int $stickerSetId = null,
public ?int $stickerSetId = null,
/**
* Sticker set version.
*
*/
public readonly ?int $stickerSetVersion = null,
public ?int $stickerSetVersion = null,
/**
* Weblocation URL.
*
*/
public readonly ?string $url= null,
public ?string $url= null,
) {
}