fix return type for application messages functions