Good luck checking for `None` equality and indent your code like 5 times... a sort of railway programming[0] avoids the awkward checks for values, making functions work with higher order types.
0: https://www.greenbird.com/news/railway-oriented-programming-....