replaceLast method
Implementation
void replaceLast(Decorator? decorator) {
if (decorator == null) {
removeLast();
} else if (isLastDecorator || _next!.isLastDecorator) {
_next = decorator;
} else {
_next!.replaceLast(decorator);
}
}