Use "/" as default prefix during attach if not specified.
The user can recover the old behavior by passing prefix="". This enables to attach children with default and save a valid result to XML. PiperOrigin-RevId: 825011185 Change-Id: Id20c2589da928bf92b77bdb01cfba73dfc1d2f52
This commit is contained in:
committed by
Copybara-Service
parent
1bfa8b6fa6
commit
2bdea1a0aa
@@ -465,7 +465,7 @@ PYBIND11_MODULE(_specs, m) {
|
||||
throw pybind11::value_error(
|
||||
"Only one of frame or site can be specified.");
|
||||
}
|
||||
const char* p = prefix.has_value() ? prefix.value().c_str() : "";
|
||||
const char* p = prefix.has_value() ? prefix.value().c_str() : "/";
|
||||
const char* s = suffix.has_value() ? suffix.value().c_str() : "";
|
||||
raw::MjsElement* attached_frame = nullptr;
|
||||
if (frame.has_value()) {
|
||||
|
||||
Reference in New Issue
Block a user