aboutsummaryrefslogtreecommitdiffstats
path: root/apps/settings
diff options
context:
space:
mode:
authorChristopher Ng <chrng8@gmail.com>2022-06-28 18:19:15 +0000
committerChristopher Ng <chrng8@gmail.com>2022-06-28 18:19:15 +0000
commit05d53c6340ffd345e7d88e19a7ee06d6b385d410 (patch)
tree3370decfa155aa328b410c9dda483fccbaa4ddfd /apps/settings
parenta1bc7700439c6f06842d42e67a0474de9faef34d (diff)
downloadnextcloud-server-05d53c6340ffd345e7d88e19a7ee06d6b385d410.tar.gz
nextcloud-server-05d53c6340ffd345e7d88e19a7ee06d6b385d410.zip
Fix undefined logger
Signed-off-by: Christopher Ng <chrng8@gmail.com>
Diffstat (limited to 'apps/settings')
-rw-r--r--apps/settings/src/components/BasicSettings/ProfileSettings.vue3
-rw-r--r--apps/settings/src/components/PersonalInfo/BiographySection/Biography.vue3
-rw-r--r--apps/settings/src/components/PersonalInfo/DisplayNameSection/DisplayName.vue3
-rw-r--r--apps/settings/src/components/PersonalInfo/EmailSection/Email.vue3
-rw-r--r--apps/settings/src/components/PersonalInfo/EmailSection/EmailSection.vue3
-rw-r--r--apps/settings/src/components/PersonalInfo/HeadlineSection/Headline.vue3
-rw-r--r--apps/settings/src/components/PersonalInfo/LanguageSection/Language.vue3
-rw-r--r--apps/settings/src/components/PersonalInfo/OrganisationSection/Organisation.vue3
-rw-r--r--apps/settings/src/components/PersonalInfo/ProfileSection/ProfileCheckbox.vue3
-rw-r--r--apps/settings/src/components/PersonalInfo/ProfileVisibilitySection/VisibilityDropdown.vue3
-rw-r--r--apps/settings/src/components/PersonalInfo/RoleSection/Role.vue3
-rw-r--r--apps/settings/src/components/PersonalInfo/shared/FederationControl.vue3
-rw-r--r--apps/settings/src/main-personal-info.js5
13 files changed, 24 insertions, 17 deletions
diff --git a/apps/settings/src/components/BasicSettings/ProfileSettings.vue b/apps/settings/src/components/BasicSettings/ProfileSettings.vue
index 9abce3d787c..8a487e4e1ea 100644
--- a/apps/settings/src/components/BasicSettings/ProfileSettings.vue
+++ b/apps/settings/src/components/BasicSettings/ProfileSettings.vue
@@ -45,6 +45,7 @@ import { showError } from '@nextcloud/dialogs'
import { saveProfileDefault } from '../../service/ProfileService'
import { validateBoolean } from '../../utils/validate'
+import logger from '../../logger'
import CheckboxRadioSwitch from '@nextcloud/vue/dist/Components/CheckboxRadioSwitch'
@@ -90,7 +91,7 @@ export default {
this.initialProfileEnabledByDefault = isEnabled
} else {
showError(errorMessage)
- this.logger.error(errorMessage, error)
+ logger.error(errorMessage, error)
}
},
},
diff --git a/apps/settings/src/components/PersonalInfo/BiographySection/Biography.vue b/apps/settings/src/components/PersonalInfo/BiographySection/Biography.vue
index ffe0029db8d..48c2bf4ff77 100644
--- a/apps/settings/src/components/PersonalInfo/BiographySection/Biography.vue
+++ b/apps/settings/src/components/PersonalInfo/BiographySection/Biography.vue
@@ -47,6 +47,7 @@ import debounce from 'debounce'
import { ACCOUNT_PROPERTY_ENUM } from '../../../constants/AccountPropertyConstants'
import { savePrimaryAccountProperty } from '../../../service/PersonalInfo/PersonalInfoService'
+import logger from '../../../logger'
export default {
name: 'Biography',
@@ -105,7 +106,7 @@ export default {
setTimeout(() => { this.showCheckmarkIcon = false }, 2000)
} else {
showError(errorMessage)
- this.logger.error(errorMessage, error)
+ logger.error(errorMessage, error)
this.showErrorIcon = true
setTimeout(() => { this.showErrorIcon = false }, 2000)
}
diff --git a/apps/settings/src/components/PersonalInfo/DisplayNameSection/DisplayName.vue b/apps/settings/src/components/PersonalInfo/DisplayNameSection/DisplayName.vue
index 0cfa630123e..58252bfbd63 100644
--- a/apps/settings/src/components/PersonalInfo/DisplayNameSection/DisplayName.vue
+++ b/apps/settings/src/components/PersonalInfo/DisplayNameSection/DisplayName.vue
@@ -48,6 +48,7 @@ import debounce from 'debounce'
import { ACCOUNT_PROPERTY_ENUM } from '../../../constants/AccountPropertyConstants'
import { savePrimaryAccountProperty } from '../../../service/PersonalInfo/PersonalInfoService'
import { validateStringInput } from '../../../utils/validate'
+import logger from '../../../logger'
// TODO Global avatar updating on events (e.g. updating the displayname) is currently being handled by global js, investigate using https://github.com/nextcloud/nextcloud-event-bus for global avatar updating
@@ -110,7 +111,7 @@ export default {
setTimeout(() => { this.showCheckmarkIcon = false }, 2000)
} else {
showError(errorMessage)
- this.logger.error(errorMessage, error)
+ logger.error(errorMessage, error)
this.showErrorIcon = true
setTimeout(() => { this.showErrorIcon = false }, 2000)
}
diff --git a/apps/settings/src/components/PersonalInfo/EmailSection/Email.vue b/apps/settings/src/components/PersonalInfo/EmailSection/Email.vue
index deb5da3a798..2559f026f71 100644
--- a/apps/settings/src/components/PersonalInfo/EmailSection/Email.vue
+++ b/apps/settings/src/components/PersonalInfo/EmailSection/Email.vue
@@ -84,6 +84,7 @@ import { showError } from '@nextcloud/dialogs'
import debounce from 'debounce'
import FederationControl from '../shared/FederationControl'
+import logger from '../../../logger'
import { ACCOUNT_PROPERTY_READABLE_ENUM, VERIFICATION_ENUM } from '../../../constants/AccountPropertyConstants'
import {
@@ -339,7 +340,7 @@ export default {
setTimeout(() => { this.showCheckmarkIcon = false }, 2000)
} else {
showError(errorMessage)
- this.logger.error(errorMessage, error)
+ logger.error(errorMessage, error)
this.showErrorIcon = true
setTimeout(() => { this.showErrorIcon = false }, 2000)
}
diff --git a/apps/settings/src/components/PersonalInfo/EmailSection/EmailSection.vue b/apps/settings/src/components/PersonalInfo/EmailSection/EmailSection.vue
index 1c548bf8355..3463daa5755 100644
--- a/apps/settings/src/components/PersonalInfo/EmailSection/EmailSection.vue
+++ b/apps/settings/src/components/PersonalInfo/EmailSection/EmailSection.vue
@@ -71,6 +71,7 @@ import HeaderBar from '../shared/HeaderBar'
import { ACCOUNT_PROPERTY_READABLE_ENUM, DEFAULT_ADDITIONAL_EMAIL_SCOPE } from '../../../constants/AccountPropertyConstants'
import { savePrimaryEmail, savePrimaryEmailScope, removeAdditionalEmail } from '../../../service/PersonalInfo/EmailService'
import { validateEmail } from '../../../utils/validate'
+import logger from '../../../logger'
const { emailMap: { additionalEmails, primaryEmail, notificationEmail } } = loadState('settings', 'personalInfoParameters', {})
const { displayNameChangeSupported } = loadState('settings', 'accountParameters', {})
@@ -182,7 +183,7 @@ export default {
handleResponse(status, errorMessage, error) {
if (status !== 'ok') {
showError(errorMessage)
- this.logger.error(errorMessage, error)
+ logger.error(errorMessage, error)
}
},
diff --git a/apps/settings/src/components/PersonalInfo/HeadlineSection/Headline.vue b/apps/settings/src/components/PersonalInfo/HeadlineSection/Headline.vue
index 2b81169bb4b..4cb7d63b522 100644
--- a/apps/settings/src/components/PersonalInfo/HeadlineSection/Headline.vue
+++ b/apps/settings/src/components/PersonalInfo/HeadlineSection/Headline.vue
@@ -47,6 +47,7 @@ import debounce from 'debounce'
import { ACCOUNT_PROPERTY_ENUM } from '../../../constants/AccountPropertyConstants'
import { savePrimaryAccountProperty } from '../../../service/PersonalInfo/PersonalInfoService'
+import logger from '../../../logger'
export default {
name: 'Headline',
@@ -105,7 +106,7 @@ export default {
setTimeout(() => { this.showCheckmarkIcon = false }, 2000)
} else {
showError(errorMessage)
- this.logger.error(errorMessage, error)
+ logger.error(errorMessage, error)
this.showErrorIcon = true
setTimeout(() => { this.showErrorIcon = false }, 2000)
}
diff --git a/apps/settings/src/components/PersonalInfo/LanguageSection/Language.vue b/apps/settings/src/components/PersonalInfo/LanguageSection/Language.vue
index ed5d6f8b5d7..99dadd449ce 100644
--- a/apps/settings/src/components/PersonalInfo/LanguageSection/Language.vue
+++ b/apps/settings/src/components/PersonalInfo/LanguageSection/Language.vue
@@ -56,6 +56,7 @@ import { showError } from '@nextcloud/dialogs'
import { ACCOUNT_SETTING_PROPERTY_ENUM } from '../../../constants/AccountPropertyConstants'
import { savePrimaryAccountProperty } from '../../../service/PersonalInfo/PersonalInfoService'
import { validateLanguage } from '../../../utils/validate'
+import logger from '../../../logger'
export default {
name: 'Language',
@@ -129,7 +130,7 @@ export default {
this.initialLanguage = language
} else {
showError(errorMessage)
- this.logger.error(errorMessage, error)
+ logger.error(errorMessage, error)
}
},
diff --git a/apps/settings/src/components/PersonalInfo/OrganisationSection/Organisation.vue b/apps/settings/src/components/PersonalInfo/OrganisationSection/Organisation.vue
index 106c5b6f6ff..4f69d7b6b9a 100644
--- a/apps/settings/src/components/PersonalInfo/OrganisationSection/Organisation.vue
+++ b/apps/settings/src/components/PersonalInfo/OrganisationSection/Organisation.vue
@@ -47,6 +47,7 @@ import debounce from 'debounce'
import { ACCOUNT_PROPERTY_ENUM } from '../../../constants/AccountPropertyConstants'
import { savePrimaryAccountProperty } from '../../../service/PersonalInfo/PersonalInfoService'
+import logger from '../../../logger'
export default {
name: 'Organisation',
@@ -105,7 +106,7 @@ export default {
setTimeout(() => { this.showCheckmarkIcon = false }, 2000)
} else {
showError(errorMessage)
- this.logger.error(errorMessage, error)
+ logger.error(errorMessage, error)
this.showErrorIcon = true
setTimeout(() => { this.showErrorIcon = false }, 2000)
}
diff --git a/apps/settings/src/components/PersonalInfo/ProfileSection/ProfileCheckbox.vue b/apps/settings/src/components/PersonalInfo/ProfileSection/ProfileCheckbox.vue
index d7e78915c5d..da3d509c2f5 100644
--- a/apps/settings/src/components/PersonalInfo/ProfileSection/ProfileCheckbox.vue
+++ b/apps/settings/src/components/PersonalInfo/ProfileSection/ProfileCheckbox.vue
@@ -40,6 +40,7 @@ import { emit } from '@nextcloud/event-bus'
import { savePrimaryAccountProperty } from '../../../service/PersonalInfo/PersonalInfoService'
import { validateBoolean } from '../../../utils/validate'
import { ACCOUNT_PROPERTY_ENUM } from '../../../constants/AccountPropertyConstants'
+import logger from '../../../logger'
export default {
name: 'ProfileCheckbox',
@@ -89,7 +90,7 @@ export default {
emit('settings:profile-enabled:updated', isEnabled)
} else {
showError(errorMessage)
- this.logger.error(errorMessage, error)
+ logger.error(errorMessage, error)
}
},
},
diff --git a/apps/settings/src/components/PersonalInfo/ProfileVisibilitySection/VisibilityDropdown.vue b/apps/settings/src/components/PersonalInfo/ProfileVisibilitySection/VisibilityDropdown.vue
index e057d5f0a08..10b2e5cea81 100644
--- a/apps/settings/src/components/PersonalInfo/ProfileVisibilitySection/VisibilityDropdown.vue
+++ b/apps/settings/src/components/PersonalInfo/ProfileVisibilitySection/VisibilityDropdown.vue
@@ -46,6 +46,7 @@ import Multiselect from '@nextcloud/vue/dist/Components/Multiselect'
import { saveProfileParameterVisibility } from '../../../service/ProfileService'
import { validateStringInput } from '../../../utils/validate'
import { VISIBILITY_PROPERTY_ENUM } from '../../../constants/ProfileConstants'
+import logger from '../../../logger'
const { profileEnabled } = loadState('settings', 'personalInfoParameters', false)
@@ -138,7 +139,7 @@ export default {
this.initialVisibility = visibility
} else {
showError(errorMessage)
- this.logger.error(errorMessage, error)
+ logger.error(errorMessage, error)
}
},
diff --git a/apps/settings/src/components/PersonalInfo/RoleSection/Role.vue b/apps/settings/src/components/PersonalInfo/RoleSection/Role.vue
index efbc06e61be..4add0d04d0d 100644
--- a/apps/settings/src/components/PersonalInfo/RoleSection/Role.vue
+++ b/apps/settings/src/components/PersonalInfo/RoleSection/Role.vue
@@ -47,6 +47,7 @@ import debounce from 'debounce'
import { ACCOUNT_PROPERTY_ENUM } from '../../../constants/AccountPropertyConstants'
import { savePrimaryAccountProperty } from '../../../service/PersonalInfo/PersonalInfoService'
+import logger from '../../../logger'
export default {
name: 'Role',
@@ -105,7 +106,7 @@ export default {
setTimeout(() => { this.showCheckmarkIcon = false }, 2000)
} else {
showError(errorMessage)
- this.logger.error(errorMessage, error)
+ logger.error(errorMessage, error)
this.showErrorIcon = true
setTimeout(() => { this.showErrorIcon = false }, 2000)
}
diff --git a/apps/settings/src/components/PersonalInfo/shared/FederationControl.vue b/apps/settings/src/components/PersonalInfo/shared/FederationControl.vue
index b14bc5165b5..5a68791f0fe 100644
--- a/apps/settings/src/components/PersonalInfo/shared/FederationControl.vue
+++ b/apps/settings/src/components/PersonalInfo/shared/FederationControl.vue
@@ -53,6 +53,7 @@ import {
UNPUBLISHED_READABLE_PROPERTIES,
} from '../../../constants/AccountPropertyConstants'
import { savePrimaryAccountPropertyScope } from '../../../service/PersonalInfo/PersonalInfoService'
+import logger from '../../../logger'
const { lookupServerUploadEnabled } = loadState('settings', 'accountParameters', {})
@@ -172,7 +173,7 @@ export default {
} else {
this.$emit('update:scope', this.initialScope)
showError(errorMessage)
- this.logger.error(errorMessage, error)
+ logger.error(errorMessage, error)
}
},
},
diff --git a/apps/settings/src/main-personal-info.js b/apps/settings/src/main-personal-info.js
index 7694fa4ff6d..d3cfd3ec9cc 100644
--- a/apps/settings/src/main-personal-info.js
+++ b/apps/settings/src/main-personal-info.js
@@ -26,8 +26,6 @@ import { loadState } from '@nextcloud/initial-state'
import { translate as t } from '@nextcloud/l10n'
import '@nextcloud/dialogs/styles/toast.scss'
-import logger from './logger'
-
import DisplayNameSection from './components/PersonalInfo/DisplayNameSection/DisplayNameSection'
import EmailSection from './components/PersonalInfo/EmailSection/EmailSection'
import LanguageSection from './components/PersonalInfo/LanguageSection/LanguageSection'
@@ -43,9 +41,6 @@ __webpack_nonce__ = btoa(getRequestToken())
const profileEnabledGlobally = loadState('settings', 'profileEnabledGlobally', true)
Vue.mixin({
- props: {
- logger,
- },
methods: {
t,
},