Swapped to fmt to be able to capture in file