Skip to content

Commit 1917c73

Browse files
committed
dev: Fix generated files
1 parent cbdcd17 commit 1917c73

File tree

4 files changed

+35
-6
lines changed

4 files changed

+35
-6
lines changed

pkg/ttnpb/end_device.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2685,7 +2685,7 @@ func (v *EndDevice) FieldIsZero(p string) bool {
26852685
return v.MacSettings.FieldIsZero("downlink_dwell_time")
26862686
case "mac_settings.downlink_dwell_time.value":
26872687
return v.MacSettings.FieldIsZero("downlink_dwell_time.value")
2688-
case "mac_settings_profile_ids":
2688+
case "mac_settings_profile_ids": // nolint: goconst
26892689
return v.MacSettingsProfileIds == nil
26902690
case "mac_settings_profile_ids.application_ids":
26912691
return v.MacSettingsProfileIds.FieldIsZero("application_ids")

pkg/ttnpb/identifiers.go

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -108,17 +108,17 @@ func (ids *MACSettingsProfileIdentifiers) IsZero() bool {
108108
}
109109

110110
// FieldIsZero returns whether path p is zero.
111-
func (v *MACSettingsProfileIdentifiers) FieldIsZero(p string) bool {
112-
if v == nil {
111+
func (ids *MACSettingsProfileIdentifiers) FieldIsZero(p string) bool {
112+
if ids == nil {
113113
return true
114114
}
115115
switch p {
116116
case "application_ids":
117-
return v.ApplicationIds == nil
117+
return ids.ApplicationIds == nil
118118
case "application_ids.application_id":
119-
return v.ApplicationIds.FieldIsZero("application_id")
119+
return ids.ApplicationIds.FieldIsZero("application_id")
120120
case "profile_id":
121-
return v.ProfileId == ""
121+
return ids.ProfileId == ""
122122
}
123123
panic(fmt.Sprintf("unknown path '%s'", p))
124124
}

pkg/util/test/constructors_generated.go

Lines changed: 9 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

sdk/js/generated/device-entity-map.json

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1489,6 +1489,26 @@
14891489
]
14901490
}
14911491
},
1492+
"mac_settings_profile_ids": {
1493+
"_root": [
1494+
"ns",
1495+
"ns"
1496+
],
1497+
"application_ids": {
1498+
"_root": [
1499+
"ns",
1500+
"ns"
1501+
],
1502+
"application_id": [
1503+
"ns",
1504+
"ns"
1505+
]
1506+
},
1507+
"profile_id": [
1508+
"ns",
1509+
"ns"
1510+
]
1511+
},
14921512
"mac_state": {
14931513
"_root": [
14941514
"ns",

0 commit comments

Comments
 (0)