extracted saving imported page into a method

Change-Id: I5a011164891f4c071e0e763fdae49532e368e0dc