MMTMMT Docs
Diagnostics

T214

destructure target list error

T214

The destructuring target count or shape does not match the returned values. Use one target per result.

Failing example

script "example"
data chart = subscribe(data.ohlcv)
fn pair() -> (int, int) { return 1, 2 }
on chart.update { let value, value = pair() }

Corrected example

script "fixed"
data chart = subscribe(data.ohlcv)
fn pair() -> (int, int) { return 1, 2 }
on chart.update { let first, second = pair() }

On this page