How to add an if statement to BindAxis

So I’m basically trying to stop the actor from being able to look in any direction when I press a key but whenever I try to put a condition on my “Look” and “Turn” it only takes the initial argument in consideration and it doesn’t refresh, I guess. I heard about ForceRebuildingKeyMaps or something like that but I don’t really know how I should handle the axis binding.