passing beautify flags as arguments to the function
(to be squashed with d24e2b3)