moved dead code to separate file
file cache working again