His statement, “But if he abandons it during the prayer, or hesitates, it becomes invalid”: “if he abandons it” means the intention. Thus, if he abandons it during the prayer, or hesitates, it becomes invalid—that is, if he abandons it during the prayer, his prayer becomes invalid.
For example, a man begins to offer a voluntary prayer, then remembers that he has something to attend to and abandons his intention. The prayer is undoubtedly invalid, due to the Prophet’s saying, “Actions are only by intentions, and every person shall have only what he intended.” This man intended to discontinue it, so it was discontinued.
His statement, “or hesitates,” means that he hesitates about discontinuing it.
For example, he hears someone knocking at the door and hesitates: Should I discontinue the prayer or continue? The author says that the prayer becomes invalid, even though he has not resolved to discontinue it. Likewise, if he hears the telephone ring and hesitates: Should he discontinue the prayer and speak, or continue? The author says that his prayer becomes invalid, because, in his view, maintaining the resolve is a condition.
Some scholars said that it is not invalidated by hesitation (1), because the basic principle is that the intention remains in effect, and such hesitation does not invalidate it. This view is correct. So long as he has not resolved to discontinue it, he remains upon his intention, and we cannot say that his prayer has become invalid merely because he hesitated about discontinuing it.
Issue: If he resolves to do something that invalidates the prayer but does not do it—for example, he resolves to speak during his prayer but does not speak, or resolves to break his ablution but does not do so—some scholars said that the prayer becomes invalid (2), because resolving to commit something that invalidates the prayer is itself resolving to discontinue the prayer, and resolving to discontinue the prayer invalidates it.