Skip to content

Commit

Permalink
Merge pull request #78 from jefft0/chore/remove-AssertOriginCall
Browse files Browse the repository at this point in the history
chore: Remove deprecated std.AssertOriginCall()
  • Loading branch information
jefft0 committed May 23, 2024
2 parents fe638ae + abfde71 commit f6472ee
Showing 1 changed file with 0 additions and 5 deletions.
5 changes: 0 additions & 5 deletions realm/public.gno
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ type UserAndPostID struct {
// Return the "thread ID" of the new post.
// (This is similar to boards.CreateThread, but no message title)
func PostMessage(body string) PostID {
std.AssertOriginCall()
caller := std.GetOrigCaller()
name := usernameOf(caller)
if name == "" {
Expand All @@ -38,7 +37,6 @@ func PostMessage(body string) PostID {
// Return the new post ID.
// (This is similar to boards.CreateReply.)
func PostReply(userPostsAddr std.Address, threadid, postid PostID, body string) PostID {
std.AssertOriginCall()
caller := std.GetOrigCaller()
if usernameOf(caller) == "" {
panic("please register")
Expand Down Expand Up @@ -69,7 +67,6 @@ func PostReply(userPostsAddr std.Address, threadid, postid PostID, body string)
// Return the new post ID.
// (This is similar to boards.CreateRepost.)
func RepostThread(userPostsAddr std.Address, threadid PostID, comment string) PostID {
std.AssertOriginCall()
caller := std.GetOrigCaller()
if userPostsAddr == caller {
panic("Cannot repost a user's own message")
Expand Down Expand Up @@ -227,7 +224,6 @@ func GetJsonHomePosts(userPostsAddr std.Address, startIndex int, endIndex int) s

// Update the caller to follow the user with followedAddr. See UserPosts.Follow.
func Follow(followedAddr std.Address) PostID {
std.AssertOriginCall()
caller := std.GetOrigCaller()
name := usernameOf(caller)
if name == "" {
Expand All @@ -245,7 +241,6 @@ func Follow(followedAddr std.Address) PostID {

// Update the caller to unfollow the user with followedAddr. See UserPosts.Unfollow.
func Unfollow(followedAddr std.Address) {
std.AssertOriginCall()
caller := std.GetOrigCaller()
name := usernameOf(caller)
if name == "" {
Expand Down

0 comments on commit f6472ee

Please sign in to comment.