Skip to content

[GitHubEnterprise-3.13] Update to 1.1.4-21328c477fcf59892ec22f32ff4cf8b7 from 1.1.4-5345cfceb2528e8e91c8d7a675d048be #1514

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"specHash": "5345cfceb2528e8e91c8d7a675d048be",
"specHash": "21328c477fcf59892ec22f32ff4cf8b7",
"generatedFiles": {
"files": [
{
Expand Down Expand Up @@ -13352,7 +13352,7 @@
},
{
"name": ".\/clients\/GitHubEnterprise-3.13\/etc\/..\/\/src\/\/Schema\/Announcement.php",
"hash": "ed48464cd8270d4a00c01d374b178871"
"hash": "27e458c6880ea55a7ce64b936f2e8c49"
},
{
"name": ".\/clients\/GitHubEnterprise-3.13\/etc\/..\/\/src\/\/Schema\/LicenseInfo.php",
Expand Down Expand Up @@ -27168,7 +27168,7 @@
},
{
"name": ".\/clients\/GitHubEnterprise-3.13\/etc\/..\/\/src\/\/Operation\/EnterpriseAdmin.php",
"hash": "8e5ed19636edd3f61c268f23d3dba92d"
"hash": "3969d0c96e854589ccfd64812d38dcba"
},
{
"name": ".\/clients\/GitHubEnterprise-3.13\/etc\/..\/\/src\/\/Operation\/SecurityAdvisories.php",
Expand Down Expand Up @@ -27748,7 +27748,7 @@
},
{
"name": ".\/clients\/GitHubEnterprise-3.13\/etc\/..\/\/src\/\/Internal\/Hydrator\/Operation\/Enterprise\/Announcement.php",
"hash": "2031eff3f5c8d7209048e852b5c84031"
"hash": "5e98612b79dbbc66f8c8e936476d0875"
},
{
"name": ".\/clients\/GitHubEnterprise-3.13\/etc\/..\/\/src\/\/Internal\/Hydrator\/Operation\/Enterprise\/Settings\/License.php",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,17 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterprise⚡️Schema
$properties['expiresAt'] = $value;

after_expiresAt:

$value = $payload['user_dismissible'] ?? null;

if ($value === null) {
$properties['userDismissible'] = null;
goto after_userDismissible;
}

$properties['userDismissible'] = $value;

after_userDismissible:
} catch (Throwable $exception) {
throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterprise\Schema\Announcement', $exception, stack: $this->hydrationStack);
}
Expand Down Expand Up @@ -198,6 +209,14 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterprise⚡

after_expiresAt: $result['expires_at'] = $expiresAt;

$userDismissible = $object->userDismissible;

if ($userDismissible === null) {
goto after_userDismissible;
}

after_userDismissible: $result['user_dismissible'] = $userDismissible;

return $result;
}

Expand Down
18 changes: 16 additions & 2 deletions clients/GitHubEnterprise-3.13/src/Schema/Announcement.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,17 @@
"examples": [
"\\"2021-01-01T00:00:00.000-07:00\\""
]
},
"user_dismissible": {
"type": [
"boolean",
"null"
],
"description": "Whether an announcement can be dismissed by the user.",
"default": false,
"examples": [
false
]
}
},
"description": "Enterprise global announcement"
Expand All @@ -43,15 +54,18 @@
public const SCHEMA_DESCRIPTION = 'Enterprise global announcement';
public const SCHEMA_EXAMPLE_DATA = '{
"announcement": "Very **important** announcement about _something_.",
"expires_at": "\\"2021-01-01T00:00:00.000-07:00\\""
"expires_at": "\\"2021-01-01T00:00:00.000-07:00\\"",
"user_dismissible": false
}';

/**
* announcement: The announcement text in GitHub Flavored Markdown. For more information about GitHub Flavored Markdown, see "[Basic writing and formatting syntax](https://docs.github.com/[email protected]/github/writing-on-github/getting-started-with-writing-and-formatting-on-github/basic-writing-and-formatting-syntax)."
* expiresAt: The time at which the announcement expires. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`. To set an announcement that never expires, omit this parameter, set it to `null`, or set it to an empty string.
* userDismissible: Whether an announcement can be dismissed by the user.
*/
public function __construct(public string|null $announcement, #[MapFrom('expires_at')]
public string|null $expiresAt,)
public string|null $expiresAt, #[MapFrom('user_dismissible')]
public bool|null $userDismissible,)
{
}
}
20 changes: 11 additions & 9 deletions etc/specs/GitHubEnterprise-3.13/current.spec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -33069,7 +33069,7 @@ paths:
"$ref": "#/components/responses/validation_failed"
x-github:
githubCloudOnly: false
enabledForGitHubApps: false
enabledForGitHubApps: true
category: reactions
subcategory: reactions
"/repos/{owner}/{repo}/issues/{issue_number}/reactions/{reaction_id}":
Expand Down Expand Up @@ -68170,6 +68170,14 @@ components:
`null`, or set it to an empty string.'
examples:
- '"2021-01-01T00:00:00.000-07:00"'
announcement-user-dismissible:
type:
- boolean
- 'null'
description: Whether an announcement can be dismissed by the user.
default: false
examples:
- false
announcement:
title: Enterprise Announcement
description: Enterprise global announcement
Expand All @@ -68179,6 +68187,8 @@ components:
"$ref": "#/components/schemas/announcement-message"
expires_at:
"$ref": "#/components/schemas/announcement-expiration"
user_dismissible:
"$ref": "#/components/schemas/announcement-user-dismissible"
required:
- announcement
license-info:
Expand Down Expand Up @@ -73261,14 +73271,6 @@ components:
- created_at
- updated_at
- visibility
announcement-user-dismissible:
type:
- boolean
- 'null'
description: Whether an announcement can be dismissed by the user.
default: false
examples:
- false
announcement-banner:
title: Announcement Banner
description: Announcement at either the repository, organization, or enterprise
Expand Down
Loading