fix crash on empty message