added extra check to ffdfappend