Added option for using either mtime or atime