Move constant to config. Reformat code