mirror of https://github.com/nextcloud/server
Fix some linter warning
Part of my ongoing battle against deprecation messages. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl> Signed-off-by: npmbuildbot[bot] <npmbuildbot[bot]@users.noreply.github.com>
This commit is contained in:
parent
1c7d089434
commit
3bca70999a
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -14,6 +14,7 @@ import DOMPurify from 'dompurify'
|
|||
import Handlebars from 'handlebars'
|
||||
import identity from 'lodash/fp/identity'
|
||||
import escapeHTML from 'escape-html'
|
||||
import { generateFilePath } from '@nextcloud/router'
|
||||
|
||||
import OC from './index'
|
||||
import {
|
||||
|
@ -49,7 +50,7 @@ const L10n = {
|
|||
}
|
||||
|
||||
const self = this
|
||||
const url = OC.filePath(appName, 'l10n', OC.getLocale() + '.json')
|
||||
const url = generateFilePath(appName, 'l10n', OC.getLocale() + '.json')
|
||||
|
||||
// load JSON translation bundle per AJAX
|
||||
return $.get(url)
|
||||
|
|
|
@ -20,6 +20,7 @@
|
|||
*/
|
||||
|
||||
import $ from 'jquery'
|
||||
import { generateFilePath } from '@nextcloud/router'
|
||||
|
||||
const loadedScripts = {}
|
||||
const loadedStyles = []
|
||||
|
@ -37,7 +38,7 @@ export const addScript = (app, script, ready) => {
|
|||
console.warn('OC.addScript is deprecated, use OCP.Loader.loadScript instead')
|
||||
|
||||
let deferred
|
||||
const path = OC.filePath(app, 'js', script + '.js')
|
||||
const path = generateFilePath(app, 'js', script + '.js')
|
||||
if (!loadedScripts[path]) {
|
||||
deferred = $.Deferred()
|
||||
$.getScript(path, () => deferred.resolve())
|
||||
|
@ -59,7 +60,7 @@ export const addScript = (app, script, ready) => {
|
|||
export const addStyle = (app, style) => {
|
||||
console.warn('OC.addStyle is deprecated, use OCP.Loader.loadStylesheet instead')
|
||||
|
||||
const path = OC.filePath(app, 'css', style + '.css')
|
||||
const path = generateFilePath(app, 'css', style + '.css')
|
||||
if (loadedStyles.indexOf(path) === -1) {
|
||||
loadedStyles.push(path)
|
||||
if (document.createStyleSheet) {
|
||||
|
|
|
@ -22,6 +22,7 @@
|
|||
import _ from 'underscore'
|
||||
import $ from 'jquery'
|
||||
import moment from 'moment'
|
||||
import { generateUrl } from '@nextcloud/router'
|
||||
|
||||
import OC from './index'
|
||||
|
||||
|
@ -105,7 +106,7 @@ export default {
|
|||
const self = this
|
||||
|
||||
$.ajax({
|
||||
url: OC.generateUrl('/login/confirm'),
|
||||
url: generateUrl('/login/confirm'),
|
||||
data: {
|
||||
password: password,
|
||||
},
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
import $ from 'jquery'
|
||||
|
||||
/**
|
||||
* Parses a URL query string into a JS map
|
||||
* @param {string} queryString query string in the format param1=1234¶m2=abcde¶m3=xyz
|
||||
|
|
Loading…
Reference in New Issue