Bug fix when pay amount dialog is closed and exception is thrown.