make utils.once protect recursive functions

Fix #226
Merge pull request #227 from phuu/fix-recursive-once-226

make utils.once protect recursive functions