corrected errors in unflatten