Add reset data button
Isolate some varrible into its scope instead exposing global scope
refactor reset data button
Merged with pw4tool