Skip to content

Commit

Permalink
remove 'revision' from lexicon package
Browse files Browse the repository at this point in the history
  • Loading branch information
bnewbold committed Dec 24, 2024
1 parent 7565e19 commit 6fd79d6
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 7 deletions.
5 changes: 2 additions & 3 deletions atproto/lexicon/catalog.go
Original file line number Diff line number Diff line change
Expand Up @@ -72,9 +72,8 @@ func (c *BaseCatalog) AddSchemaFile(sf SchemaFile) error {
return err
}
s := Schema{
ID: name,
Revision: sf.Revision,
Def: def.Inner,
ID: name,
Def: def.Inner,
}
c.schemas[name] = s
}
Expand Down
1 change: 0 additions & 1 deletion atproto/lexicon/language.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ import (
type SchemaFile struct {
Lexicon int `json:"lexicon,const=1"`
ID string `json:"id"`
Revision *int `json:"revision,omitempty"`
Description *string `json:"description,omitempty"`
Defs map[string]SchemaDef `json:"defs"`
}
Expand Down
5 changes: 2 additions & 3 deletions atproto/lexicon/lexicon.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,8 @@ var LenientMode ValidateFlags = AllowLegacyBlob | AllowLenientDatetime

// Represents a Lexicon schema definition
type Schema struct {
ID string
Revision *int
Def any
ID string
Def any
}

// Checks Lexicon schema (fetched from the catalog) for the given record, with optional flags tweaking default validation rules.
Expand Down

0 comments on commit 6fd79d6

Please # to comment.