mirror of
https://github.com/digitalocean/nginxconfig.io
synced 2024-11-10 12:34:12 +00:00
Clean up var declaration
This commit is contained in:
parent
734a27a29d
commit
6c4afdeb6f
5 changed files with 5 additions and 10 deletions
|
@ -155,8 +155,7 @@
|
|||
// Disable everything if PHP is disabled
|
||||
'$props.data.php': {
|
||||
handler(data) {
|
||||
const state = data.computed;
|
||||
if (state) {
|
||||
if (data.computed) {
|
||||
this.$props.data.wordPressRules.enabled = true;
|
||||
this.$props.data.wordPressRules.computed = this.$props.data.wordPressRules.value;
|
||||
this.$props.data.drupalRules.enabled = true;
|
||||
|
|
|
@ -111,8 +111,7 @@
|
|||
// Disable Django if Python is disabled
|
||||
'$props.data.python': {
|
||||
handler(data) {
|
||||
const state = data.computed;
|
||||
if (state) {
|
||||
if (data.computed) {
|
||||
this.$props.data.djangoRules.enabled = true;
|
||||
this.$props.data.djangoRules.computed = this.$props.data.djangoRules.value;
|
||||
} else {
|
||||
|
|
|
@ -131,8 +131,7 @@
|
|||
// Disable all options if Reverse proxy is disabled
|
||||
'$props.data.reverseProxy': {
|
||||
handler(data) {
|
||||
const state = data.computed;
|
||||
if (state) {
|
||||
if (data.computed) {
|
||||
this.$props.data.path.enabled = true;
|
||||
this.$props.data.path.computed = this.$props.data.path.value;
|
||||
this.$props.data.proxyPass.enabled = true;
|
||||
|
|
|
@ -158,8 +158,7 @@
|
|||
// Disable all options (expect legacy php) if root is disabled
|
||||
'$props.data.root': {
|
||||
handler(data) {
|
||||
const state = data.computed;
|
||||
if (state) {
|
||||
if (data.computed) {
|
||||
this.$props.data.index.enabled = true;
|
||||
this.$props.data.index.computed = this.$props.data.index.value;
|
||||
this.$props.data.fallbackHtml.enabled = true;
|
||||
|
|
|
@ -188,8 +188,7 @@
|
|||
'$props.data.wwwSubdomain': {
|
||||
handler(data) {
|
||||
// This might cause recursion, but seems not to
|
||||
const state = data.computed;
|
||||
if (state) {
|
||||
if (data.computed) {
|
||||
this.$props.data.cdnSubdomain.enabled = true;
|
||||
this.$props.data.cdnSubdomain.computed = this.$props.data.cdnSubdomain.value;
|
||||
} else {
|
||||
|
|
Loading…
Reference in a new issue