adjust endpoints