more flexibility with the msg function