Future chainHandler<T>({ required List<Function> handles, }) async { for (var handle in handles) { bool isHandle = await handle(); if (isHandle) { break; } } }