Skip to content

Commit

Permalink
Use docker image Node 8.7 with Yarn 1.2.0
Browse files Browse the repository at this point in the history
  • Loading branch information
clintonwoo committed Oct 12, 2017
1 parent d534bcd commit bad9435
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
4 changes: 2 additions & 2 deletions Dockerfile
@@ -1,5 +1,5 @@
# DEV BUILD STEP
FROM node:8.5-alpine as devBuild
FROM node:8.7-alpine as devBuild
WORKDIR /usr/src/app

# Copy the source and build
Expand All @@ -9,7 +9,7 @@ RUN yarn run build

# PROD BUILD STEP
# Using latest LTS release of Node (comes with Yarn package manager by default)
FROM node:8.5-alpine
FROM node:8.7-alpine

# Create an app directory on the container
WORKDIR /usr/src/app
Expand Down
5 changes: 2 additions & 3 deletions src/helpers/convertNumberToTimeAgo.js
@@ -1,7 +1,6 @@
export default (number) => {
const date = new Date(number);
const now = new Date();
const timeAgo = now.valueOf() - date.valueOf();
const now = +new Date();
const timeAgo = now - number;

const ONE_YEAR = 3.154e+10;
const ONE_MONTH = 2.628e+9;
Expand Down

0 comments on commit bad9435

Please sign in to comment.