Its not possible - the edit() call is done as a part of a callback that is performed at the end of createThumbnailFromSource().