toggle method

Future<OnyxMessage?> toggle()

Implementation

Future<OnyxMessage?> toggle() async {
  if (active) {
    return release();
  } else {
    return trigger();
  }
}