Skip to content

Commit 5384088

Browse files
committed
Minor changes to remove un-needed returns
1 parent af64466 commit 5384088

2 files changed

Lines changed: 4 additions & 11 deletions

File tree

Source/Plugins/NetworkEvents/NetworkEvents.cpp

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -283,20 +283,14 @@ String NetworkEvents::handleSpecialMessages(const String& s)
283283
}
284284
}
285285

286-
if (triggerEvent(getTimestamp(currEventChannel), currEventChannel, onOff))
287-
{
288-
return "Success";
289-
}
290-
else
291-
{
292-
return "Failed";
293-
}
286+
triggerEvent(getTimestamp(currEventChannel), currEventChannel, onOff);
287+
return "TTL Handled";
294288
}
295289

296290
return String ("NotHandled");
297291
}
298292

299-
bool NetworkEvents::triggerEvent(juce::int64 bufferTs, int eventChannel, bool onOff)
293+
void NetworkEvents::triggerEvent(juce::int64 bufferTs, int eventChannel, bool onOff)
300294
{
301295
if (onOff)
302296
{
@@ -312,7 +306,6 @@ bool NetworkEvents::triggerEvent(juce::int64 bufferTs, int eventChannel, bool on
312306
TTLEventPtr eventOff = TTLEvent::createTTLEvent(TTLChannel, bufferTs, &ttlDataOff, sizeof(juce::uint8), eventChannel);
313307
addEvent(TTLChannel, eventOff, 0);
314308
}
315-
return true;
316309
}
317310

318311

Source/Plugins/NetworkEvents/NetworkEvents.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ class NetworkEvents : public GenericProcessor
182182
const EventChannel* messageChannel{ nullptr };
183183
const EventChannel* TTLChannel{ nullptr };
184184

185-
bool triggerEvent(juce::int64 bufferTs, int eventChannel, bool OnOff);
185+
void triggerEvent(juce::int64 bufferTs, int eventChannel, bool OnOff);
186186

187187
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (NetworkEvents);
188188
};

0 commit comments

Comments
 (0)