add logging in hasDocAppScript