found a better way to handle messages