fixed time warning, added filePath parameter