Added support for external files