Skip to content

Commit

Permalink
Separate KeyState from DoorState
Browse files Browse the repository at this point in the history
  • Loading branch information
niwaniwa committed Apr 6, 2024
1 parent c26a937 commit ca82963
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 6 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Added

### Changed
- Separate KeyState from DoorState

### Fixed

Expand Down
6 changes: 0 additions & 6 deletions pkg/entity/DoorState.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,6 @@ package entity

import "time"

type KeyState struct {
Open bool `json:"open"`
Timestamp time.Time `json:"timestamp"`
DeviceID string `json:"deviceID"`
}

type DoorState struct {
IsOpen bool `json:"is-open"`
Timestamp time.Time `json:"timestamp"`
Expand Down
9 changes: 9 additions & 0 deletions pkg/entity/KeyState.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
package entity

import "time"

type KeyState struct {
Open bool `json:"open"`
Timestamp time.Time `json:"timestamp"`
DeviceID string `json:"deviceID"`
}

0 comments on commit ca82963

Please sign in to comment.