Bug fix

Fix bug that calls wrong reset function