Add additional checks and logs