# P009

> postfix `!` is not supported

**Severity** Error

A postfix `!` (a "non-null assertion") is not part of the language. Flowscope Script never lets you claim that a value is present without checking it, because a missing bar or an empty book is a normal situation in market data.

Check the value with `if x != null` first, or provide a fallback with `x ?? fallback`.

## Failing example

```flowscope
script "Body size"
data chart = subscribe(data.ohlcv)
plot body = plot.histogram(title: "Body")
on chart.close {
  let c = chart.close!
  let o = chart.open!
  body.plot(math.abs(c - o))
}
```

## Fixed example

```flowscope
script "Body size"
data chart = subscribe(data.ohlcv)
plot body = plot.histogram(title: "Body")
on chart.close {
  let c = chart.close
  let o = chart.open
  if c != null && o != null {
    body.plot(math.abs(c - o))
  }
}
```

## Related

- [P008](/docs/scripting/reference/diagnostics/p008)
- [N001](/docs/scripting/reference/diagnostics/n001)
