@turingconsulting
We can see how we can perform the same checks just by validating if the queried storage ID is less than 2. This can lead to significant gas improvements even if not performed with assembly, as stated in the following snapshot comparing the differences: