File tree Expand file tree Collapse file tree 1 file changed +11
-4
lines changed
HTTPShortcuts/app/src/main/kotlin/ch/rmy/android/http_shortcuts/data/models Expand file tree Collapse file tree 1 file changed +11
-4
lines changed Original file line number Diff line number Diff line change @@ -37,8 +37,15 @@ class Shortcut() : RealmObject {
3737 if (executionType.usesResponse) {
3838 responseHandling = ResponseHandling ()
3939 }
40- if (executionType == ShortcutExecutionType .MQTT ) {
41- url = " tcp://"
40+ when (executionType) {
41+ ShortcutExecutionType .MQTT -> {
42+ url = " tcp://"
43+ }
44+ ShortcutExecutionType .WAKE_ON_LAN -> {
45+ wolBroadcastAddress = " 255.255.255.255"
46+ wolPort = 9
47+ }
48+ else -> Unit
4249 }
4350 this .categoryId = categoryId
4451 }
@@ -196,8 +203,8 @@ class Shortcut() : RealmObject {
196203 var runInForegroundService: Boolean = false
197204
198205 var wolMacAddress: String = " "
199- var wolPort: Int = 9
200- var wolBroadcastAddress: String = " 255.255.255.255 "
206+ var wolPort: Int = 0
207+ var wolBroadcastAddress: String = " "
201208
202209 fun allowsBody (): Boolean =
203210 METHOD_POST == method ||
You can’t perform that action at this time.
0 commit comments