-
Notifications
You must be signed in to change notification settings - Fork 386
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
refactor: r/demo/users
#3166
Draft
leohhhn
wants to merge
95
commits into
gnolang:master
Choose a base branch
from
leohhhn:refac/users
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+1,023
−1,089
Draft
refactor: r/demo/users
#3166
Changes from 40 commits
Commits
Show all changes
95 commits
Select commit
Hold shift + click to select a range
38c2b9a
update user rendering
leohhhn 4970a59
save
leohhhn 833576b
Merge branch 'master' into refac/users
leohhhn 2c4f497
register
leohhhn 6f9b787
Merge branch 'master' into refac/users
leohhhn 74d6ae7
add gnoland/users, expand sys/users
leohhhn 487775b
add resolving
leohhhn 25c3fa1
pausable to sys/users
leohhhn d06515e
update regex & add godoc
leohhhn 905bc10
update regex & add godoc
leohhhn 970b3f0
save
leohhhn 0ad5292
save
leohhhn 3d72544
fix err name
leohhhn 2f68087
Merge branch 'master' into refac/users
leohhhn 114de1b
Merge branch 'master' into refac/users
leohhhn a3ed4e6
add paginated fetch
leohhhn b7cc608
add list by prefix
leohhhn 3e58017
fix imports
leohhhn 69cfe1c
add admin tests
leohhhn 46fcc93
fix
leohhhn 9ee9c41
Merge branch 'refs/heads/master' into refac/users
leohhhn 065b2de
rename func
leohhhn f94a97d
save
leohhhn 1f0f9a1
add xxx
leohhhn 1ad9c57
add cmt
leohhhn c036996
username>name, add tests
leohhhn fc2a105
Merge branch 'refs/heads/master' into refac/users
leohhhn db1731e
rename files, add util_test
leohhhn a1b40fe
add test
leohhhn 21f4379
move pusers
leohhhn de48585
simplify p/users
leohhhn 6b39d88
add ctor
leohhhn 408db75
pusers>susers
leohhhn 7939469
extendeduser
leohhhn 7a8795a
rm comment
leohhhn ffef138
rm error
leohhhn 49f8c7d
Merge branch 'master' into refac/users
leohhhn c0067c5
rm pointer
leohhhn 0dadb34
rm pointer
leohhhn 2bb8e7d
rm newuser
leohhhn 64f9455
save
leohhhn d9aa544
Merge branch 'refs/heads/master' into refac/users
leohhhn 1a94d25
rm extendeduserstore
leohhhn 5bee1ee
rm update bio
leohhhn 5a02dc6
rm prereg
leohhhn 0e07c53
revert prereg
leohhhn 776e1ac
rm extuserstore
leohhhn 411965b
lookup
leohhhn 285b26f
rm restricted
leohhhn 882711a
aliasstore
leohhhn c871060
save
leohhhn 61d438c
rename aliasstore & regex
leohhhn bc02264
move verifier
leohhhn 2454e8e
add cmt
leohhhn e20299d
fix verifier, comment out resolveaddress funcs
leohhhn d27845e
add cmt
leohhhn 0f335e1
expose ownable & pausable apis
leohhhn 3f3e0bd
imports
leohhhn ee8e670
verifiy
leohhhn a2a17bc
Merge branch 'refs/heads/master' into refac/users
leohhhn b00cc3a
update verifier
leohhhn b73c944
add verifier tests, modify store
leohhhn b34e0ea
add fetcher funcs
leohhhn e1d1945
update tests
leohhhn 75a87e0
update gnoland/users
leohhhn e92964c
Merge branch 'master' into refac/users
leohhhn e1f8e58
render
leohhhn c4098d9
save
leohhhn c455438
rm aon
leohhhn 03b246e
rm lookup ctr
leohhhn 0abf40d
field
leohhhn f964e6f
ctr
leohhhn 3e99909
rm get all names
leohhhn 7acd8b1
update store
leohhhn 7841aa3
store
leohhhn 8bbf5ae
Merge branch 'refs/heads/master' into refac/users
leohhhn 55573ee
rm cmts
leohhhn 18a9c50
rm old impl
leohhhn 2bf6319
add new impl, fix tests
leohhhn 3338554
add test
leohhhn 001d759
add events
leohhhn a11686a
update verifier
leohhhn 926e50f
update comments
leohhhn b9f0e19
rm unused const
leohhhn 5b557a8
add validateCall
leohhhn 5e97815
Merge branch 'master' into refac/users
leohhhn ef9338f
update r/gnoland/users
leohhhn defba3b
update deleteuser
leohhhn 455b724
rm comment, extra file
leohhhn 7a0cbe3
fix verifier tests
leohhhn 8fdc53f
fix deletion
leohhhn ee7b38e
add govdao verifier update
leohhhn 742f48f
fix imports
leohhhn da6ae8a
switch err checks
leohhhn 12d0101
add package desc
leohhhn File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
module gno.land/p/sys/users | ||
|
||
require gno.land/p/demo/ufmt v0.0.0-latest |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
package users | ||
|
||
import ( | ||
"std" | ||
|
||
"gno.land/p/demo/ufmt" | ||
) | ||
|
||
type User struct { | ||
Address std.Address | ||
Name string | ||
} | ||
|
||
func (u *User) Render() string { | ||
out := ufmt.Sprintf("# User %s\n\n", u.Name) | ||
out += ufmt.Sprintf("- Address: %s\n\n", u.Address.String()) | ||
|
||
return out | ||
} | ||
|
||
// AddressOrName can be used for resolving either the address or the username | ||
type AddressOrName string | ||
|
||
func (aon AddressOrName) IsName() bool { | ||
return aon != "" && aon[0] == '@' | ||
} | ||
|
||
func (aon AddressOrName) Name() (string, bool) { | ||
if len(aon) >= 2 && aon[0] == '@' { | ||
return string(aon[1:]), true | ||
} | ||
|
||
return "", false | ||
} |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do we still need this? where?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
rm'd c455438