forked from svrjs/svrjs
Fix bug with "ext" variable passed to .tar.gz mod handler
This commit is contained in:
parent
82b0510774
commit
a33a86ee62
1 changed files with 2 additions and 1 deletions
|
@ -13,7 +13,8 @@ module.exports = (legacyMod) => {
|
||||||
let middleware = (req, res, logFacilities, config, next) => {
|
let middleware = (req, res, logFacilities, config, next) => {
|
||||||
let ext = req.parsedURL.pathname.match(/[^/]\.([^.]+)$/);
|
let ext = req.parsedURL.pathname.match(/[^/]\.([^.]+)$/);
|
||||||
if (!ext) ext = "";
|
if (!ext) ext = "";
|
||||||
|
else ext = ext[1].toLowerCase();
|
||||||
|
|
||||||
// Function to parse incoming POST data from the request
|
// Function to parse incoming POST data from the request
|
||||||
const parsePostData = (options, callback) => {
|
const parsePostData = (options, callback) => {
|
||||||
// If the request method is not POST, return a 405 Method Not Allowed error
|
// If the request method is not POST, return a 405 Method Not Allowed error
|
||||||
|
|
Reference in a new issue