before refreshing line endings