Fixing undefined $timestamp variable.