Added new app config param to allow disabling short URL visits tracking

This commit is contained in:
Alejandro Celaya
2018-01-14 09:13:49 +01:00
parent ce9d6642d4
commit 5fd34e03fc
4 changed files with 38 additions and 6 deletions

View File

@@ -24,14 +24,21 @@ class ApplicationConfigCustomizer implements ConfigCustomizerInterface
return;
}
$validator = function ($value) {
return $value;
};
$appConfig->setApp([
'SECRET' => $io->ask(
'Define a secret string that will be used to sign API tokens (leave empty to autogenerate one)',
null,
function ($value) {
return $value;
}
$validator
) ?: $this->generateRandomString(32),
'DISABLE_TRACK_PARAM' => $io->ask(
'Provide a parameter name that you will be able to use to disable tracking on specific request to '
. 'short URLs (leave empty and this feature won\'t be enabled)',
null,
$validator
),
]);
}
}