Removing folders and fixing entity null issues