Skip to content

Commit

Permalink
refactor(user): [PPT-1484] use property instead of getter
Browse files Browse the repository at this point in the history
  • Loading branch information
chillfox committed Aug 29, 2024
1 parent e9edfd3 commit 4899417
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/placeos-models/user.cr
Original file line number Diff line number Diff line change
Expand Up @@ -20,17 +20,17 @@ module PlaceOS::Model
struct WorktimeBlock
include JSON::Serializable

getter start_time : Float64
getter end_time : Float64
getter location : String = ""
property start_time : Float64
property end_time : Float64
property location : String = ""
end

# day_of_week: Index of the day of the week. `0` being Sunday
struct WorktimePreference
include JSON::Serializable

getter day_of_week : Int32
getter blocks : Array(WorktimeBlock) = [] of WorktimeBlock
property day_of_week : Int32
property blocks : Array(WorktimeBlock) = [] of WorktimeBlock
end

attribute name : String, es_subfield: "keyword"
Expand Down

0 comments on commit 4899417

Please sign in to comment.