CodeQL queries 1.25
Skip to end of metadata
Go to start of metadata

Finds return statements that return 'null'.

import csharp

from ReturnStmt r
where r.getExpr() instanceof NullLiteral
select r