fixed some protocol issues