From 0935765ac7d0cf04284951ffb1061859bd127098 Mon Sep 17 00:00:00 2001 From: Mike Cao Date: Sat, 26 Sep 2020 22:02:10 -0700 Subject: [PATCH] Try another path. --- components/layout/Header.module.css | 6 +++++- lib/request.js | 6 +----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/components/layout/Header.module.css b/components/layout/Header.module.css index 63d68ab9..b7fdc62c 100644 --- a/components/layout/Header.module.css +++ b/components/layout/Header.module.css @@ -5,6 +5,9 @@ .title { font-size: var(--font-size-large); + display: flex; + align-items: center; + line-height: 1.4; } .logo { @@ -26,11 +29,12 @@ .buttons { display: flex; justify-content: flex-end; + align-items: center; } @media only screen and (max-width: 992px) { .title { - text-align: center; + justify-content: center; } .nav { diff --git a/lib/request.js b/lib/request.js index 052f7200..b30a710d 100644 --- a/lib/request.js +++ b/lib/request.js @@ -3,8 +3,6 @@ import requestIp from 'request-ip'; import { browserName, detectOS } from 'detect-browser'; import isLocalhost from 'is-localhost-ip'; import maxmind from 'maxmind'; -import getConfig from 'next/config'; -const { serverRuntimeConfig } = getConfig(); import { DESKTOP_OS, @@ -63,9 +61,7 @@ export async function getCountry(req, ip) { } // Database lookup - const lookup = await maxmind.open( - path.resolve(serverRuntimeConfig.PROJECT_ROOT, 'public/geo/GeoLite2-Country.mmdb'), - ); + const lookup = await maxmind.open(path.resolve('./public/geo/GeoLite2-Country.mmdb')); const result = lookup.get(ip);