Add ad and fix bug.