   });
 
   server.on( "/", HTTP_GET, [] ( AsyncWebServerRequest * request ) {
-    if ( htmlUnmodified( request, date ) ) return request->send(304);
+    if ( htmlUnmodified( request, modifiedDate ) ) return request->send(304);
     AsyncWebServerResponse *response = request->beginResponse_P( 200, HEADER_HTML, index_htm, index_htm_len );
-    response->addHeader( HEADER_LASTMODIFIED, date );
+    response->addHeader( HEADER_LASTMODIFIED, modifiedDate );
     request->send( response );
   });
 
   //  /channels or 'channels.htm'
   server.on( "/channels", HTTP_GET, [] ( AsyncWebServerRequest * request ) {
-    if ( htmlUnmodified( request, date ) ) return request->send(304);
+    if ( htmlUnmodified( request, modifiedDate ) ) return request->send(304);
     AsyncWebServerResponse *response = request->beginResponse_P( 200, HEADER_HTML, channels_htm, channels_htm_len );
-    response->addHeader( HEADER_LASTMODIFIED, date );
+    response->addHeader( HEADER_LASTMODIFIED, modifiedDate );
     request->send( response );
   });
 
   //  /editor or 'editor.htm'
   server.on( "/editor", HTTP_GET, [] ( AsyncWebServerRequest * request ) {
-    if ( htmlUnmodified( request, date ) ) return request->send(304);
+    if ( htmlUnmodified( request, modifiedDate ) ) return request->send(304);
     AsyncWebServerResponse *response = request->beginResponse_P( 200, HEADER_HTML, editor_htm, editor_htm_len );
-    response->addHeader( HEADER_LASTMODIFIED, date );
+    response->addHeader( HEADER_LASTMODIFIED, modifiedDate );
     request->send( response );
   });
 
   //  /logs or 'logs.htm'
   server.on( "/logs", HTTP_GET, [] ( AsyncWebServerRequest * request ) {
-    if ( htmlUnmodified( request, date ) ) return request->send(304);
+    if ( htmlUnmodified( request, modifiedDate ) ) return request->send(304);
     AsyncWebServerResponse *response = request->beginResponse_P( 200, HEADER_HTML, logs_htm, logs_htm_len );
-    response->addHeader( HEADER_LASTMODIFIED, date );
+    response->addHeader( HEADER_LASTMODIFIED, modifiedDate );
     request->send( response );
   });
 
   //  /setup or 'setup.htm'
   server.on( "/setup", HTTP_GET, [] ( AsyncWebServerRequest * request ) {
-    if ( htmlUnmodified( request, date ) ) return request->send(304);
+    if ( htmlUnmodified( request, modifiedDate ) ) return request->send(304);
     AsyncWebServerResponse *response = request->beginResponse_P( 200, HEADER_HTML, setup_htm, setup_htm_len );
-    response->addHeader( HEADER_LASTMODIFIED, date );
+    response->addHeader( HEADER_LASTMODIFIED, modifiedDate );
     request->send( response );
   });
 
   //  /filemanager or 'fileman.htm'
   server.on( "/filemanager", HTTP_GET, [] ( AsyncWebServerRequest * request ) {
-    if ( htmlUnmodified( request, date ) ) return request->send(304);
+    if ( htmlUnmodified( request, modifiedDate ) ) return request->send(304);
     AsyncWebServerResponse *response = request->beginResponse_P( 200, HEADER_HTML, fileman_htm, fileman_htm_len );
-    response->addHeader( HEADER_LASTMODIFIED, date );
+    response->addHeader( HEADER_LASTMODIFIED, modifiedDate );
     request->send( response );
   });
 


    else if ( request->hasArg( "sensor" ) ) {
      if ( !logger.sensorCount() ) return request->send( 501, HEADER_HTML, NOT_PRESENT_ERROR_501 );
      if ( !request->hasArg( "number" ) ) return request->send( 400, HEADER_HTML, "No sensornumber" );
      uint8_t num = request->arg( "number" ).toInt();
      if ( num >= logger.sensorCount() ) return request->send( 400, HEADER_HTML, "Invalid sensornumber" );
      sensorName_t name;
      sensorId_t id;
      AsyncResponseStream *response = request->beginResponseStream( HEADER_HTML );

    }

    else {
      return request->send( 400, HEADER_HTML, INVALID_OPTION );
    }
  });

  server.on( "/api/setdevice", HTTP_POST, []( AsyncWebServerRequest * request ) {
    if ( !request->authenticate( WWW_USERNAME, preferences.getString( PASSWD_KEY_NVS, WWW_DEFAULT_PASSWD ).c_str() ) ) {
      return request->requestAuthentication();
    }

    else if ( request->hasArg( "hostname" ) ) {
