Fix bug in helper