Updated calcuation of File objects since File and Dir objects are now independent.