updated format function

It did not survived antler minification