Crash after a while when constantly reading variable

The problem is that in this case the variable isn’t actually “NULL” but “Invalid” and even if it was NULL, checking it would not solve my problem of it suddenly getting deleted.
Anyhow, Jin_VE solved it but thanks for the answer