diff --git a/lib/config/expression.cpp b/lib/config/expression.cpp index 65e0a3e97..43d164faf 100644 --- a/lib/config/expression.cpp +++ b/lib/config/expression.cpp @@ -792,8 +792,14 @@ bool IndexerExpression::GetReference(ScriptFrame& frame, bool init_dict, Value * *parent = operand1.GetValue(); } - ExpressionResult operand2 = m_Operand2->Evaluate(frame); - index->Set(operand2.GetValue()); + auto lit (dynamic_cast(m_Operand2.get())); + + if (lit && lit->GetValue().IsString()) { + index->Set(&lit->GetValue().Get()); + } else { + ExpressionResult operand2 = m_Operand2->Evaluate(frame); + index->Set(operand2.GetValue()); + } if (dhint) { if (psdhint)