YOU SAID:
I was about to leave the restaurant when my friends arrived.
INTO JAPANESE
友達が到着したとき、私はレストランを出ようとしていました。
BACK INTO ENGLISH
When my friend arrived, I was about to leave the restaurant.
INTO JAPANESE
友達が到着したとき、私はレストランを出ようとしていました。
BACK INTO ENGLISH
When my friend arrived, I was about to leave the restaurant.
That didn't even make that much sense in English.