File tree 1 file changed +4
-2
lines changed
1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -186,12 +186,14 @@ const NotificationSequence blink_sequence = {
186
186
NULL ,
187
187
};
188
188
static void start_blink (State * state ) {
189
+ if (!state -> ctx .led_indicator ) return ;
189
190
uint16_t period = delays [state -> delay ];
190
191
if (period <= 100 ) period += 30 ;
191
192
blink_message .data .led_blink .period = period ;
192
193
notification_message_block (state -> ctx .notification , & blink_sequence );
193
194
}
194
195
static void stop_blink (State * state ) {
196
+ if (!state -> ctx .led_indicator ) return ;
195
197
notification_message_block (state -> ctx .notification , & sequence_blink_stop );
196
198
}
197
199
@@ -228,7 +230,7 @@ static int32_t adv_thread(void* _ctx) {
228
230
Payload * payload = & attacks [state -> index ].payload ;
229
231
const Protocol * protocol = attacks [state -> index ].protocol ;
230
232
if (!payload -> random_mac ) randomize_mac (state );
231
- if ( state -> ctx . led_indicator ) start_blink (state );
233
+ start_blink (state );
232
234
if (furi_hal_bt_extra_beacon_is_active ()) {
233
235
furi_check (furi_hal_bt_extra_beacon_stop ());
234
236
}
@@ -247,7 +249,7 @@ static int32_t adv_thread(void* _ctx) {
247
249
furi_check (furi_hal_bt_extra_beacon_stop ());
248
250
}
249
251
250
- if ( state -> ctx . led_indicator ) stop_blink (state );
252
+ stop_blink (state );
251
253
return 0 ;
252
254
}
253
255
You can’t perform that action at this time.
0 commit comments