This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* Add this as first line to app.js speed up Heroku nodejs application | |
*/ | |
if (process.env.NODE_ENV === 'production') { | |
var nullfun = function () {}; | |
console.log = nullfun; | |
console.info = nullfun; | |
console.error = nullfun; | |
console.warn = nullfun; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* | |
* To protect the application from public view | |
* include the file in the first line of your index.php | |
*/ | |
$coverkey = 'yourprotectionkey'; | |
if (!$_COOKIE['coverkey'] == $coverkey) { | |
if ($_POST['key'] == $coverkey) { | |
setcookie('coverkey', $coverkey); | |
} else { |