added app_name handling