File cleanup and made is more generic for value