fix double submit bug