rename helpers -> dateUtils and add header

Signed-off-by: Adam Warner <me@adamwarner.co.uk>
This commit is contained in:
Adam Warner
2019-11-25 19:53:47 +00:00
parent 43532a04d0
commit 255d228c19
2 changed files with 11 additions and 1 deletions
+1 -1
View File
@@ -11,7 +11,7 @@
import React, { Component } from "react";
import { animateScroll } from "react-scroll";
import { WithAPIData } from "../common/WithAPIData";
import { humanTimestamp } from "../../util/helpers";
import { humanTimestamp } from "../../util/dateUtils";
import api from "../../util/api";
export interface LiveLogProps {
@@ -1,3 +1,13 @@
/* Pi-hole: A black hole for Internet advertisements
* (c) 2019 Pi-hole, LLC (https://pi-hole.net)
* Network-wide ad blocking via your own hardware.
*
* Web Interface
* Date/Time utility functions
*
* This file is copyright under the latest version of the EUPL.
* Please see LICENSE file for your rights under this license. */
export function humanTimestamp(input: number) {
var date = new Date(input * 1000);
var hours = date.getHours();