fixed drop action to check for database existence before dropping