Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

[Uid] Add NilUlid#41802

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
fabpot merged 1 commit intosymfony:5.4fromfancyweb:uid/nil-ulid
Jun 27, 2021
Merged

[Uid] Add NilUlid#41802

fabpot merged 1 commit intosymfony:5.4fromfancyweb:uid/nil-ulid
Jun 27, 2021

Conversation

@fancyweb
Copy link
Contributor

QA
Branch?5.4
Bug fix?no
New feature?yes
Deprecations?no
Tickets-
LicenseMIT
Doc PR-

NilUlid is not really official but I think it would be useful. The goal is to be able to donew NilUlid(); instead ofnew Ulid('00000000000000000000000000'); and therefore to detect it more easily (like for theNilUuid). Currently I'm creating the class manually. My use case is using it as a placeholder.

$ulid = (newUuid($ulid))->toBinary();
}elseif (22 ===\strlen($ulid) &&22 ===strspn($ulid, BinaryUtil::BASE58[''])) {
$ulid = BinaryUtil::fromBase($ulid, BinaryUtil::BASE58);
$ulid =str_pad(BinaryUtil::fromBase($ulid, BinaryUtil::BASE58),16,"\0", \STR_PAD_LEFT);
Copy link
ContributorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Needs#41801

@nicolas-grekasnicolas-grekas added this to the5.4 milestoneJun 23, 2021
@fabpot
Copy link
Member

Thank you@fancyweb.

@fabpotfabpot merged commitfa0e5a0 intosymfony:5.4Jun 27, 2021
@fancywebfancyweb deleted the uid/nil-ulid branchJune 28, 2021 07:13
This was referencedNov 5, 2021
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@nicolas-grekasnicolas-grekasnicolas-grekas approved these changes

@fabpotfabpotfabpot approved these changes

@derrabusderrabusderrabus approved these changes

@chalasrchalasrchalasr approved these changes

+1 more reviewer

@ogizanagiogizanagiogizanagi left review comments

Reviewers whose approvals may not affect merge requirements

Assignees

No one assigned

Projects

None yet

Milestone

5.4

Development

Successfully merging this pull request may close these issues.

7 participants

@fancyweb@fabpot@nicolas-grekas@derrabus@ogizanagi@chalasr@carsonbot

[8]ページ先頭

©2009-2025 Movatter.jp