Nice one. I think you got everything covered. But you move this logic to line 123 so that this is the default logic which can be overridden. (in that case you can remove the if)