[lnst] Fix "Undefined variable 'directory'" error