BibDocFile: undefined variable fix

* Fixes internal server error for when directories are missing on the
  filesystem.

* Applies fix from PU to master. The fix was overwritten by the recent
  large master to next merge (eefac3e73d8dd5b7c5ac1a47cb298431f4a8662f).

Signed-off-by: Lars Holm Nielsen <lars.holm.nielsen@cern.ch>