Trying to understand why only an action is performed