LuCI - OpenWrt Configuration Interface
Find a file
Jo-Philipp Wich 31a27f3087 luci-base: properly handle promise targets in Request.request()
Under some circumstances, ubus RPC requests may be initiated while LuCI is
still resolving the `rpcBaseURL` value. In this situation, the `target`
argument of the `request()` call will be a pending promise object which
results in an invalid URL when serialized by `expandURL()`, leading to an
`Failed to execute 'open' on 'XMLHttpRequest': Invalid URL` exception.

This commonly occured on the index status page which immediately initiates
ubus RPC calls on load to discover existing status page partials.

Solve the issue by filtering the given `target` argument through
`Promise.resolve()` before expanding the URL and initiating the actual
request.

Fixes: #3747
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit 5663fd596b)
2022-02-21 15:06:41 +01:00
applications treewide: resync and merge master translations 2022-02-16 00:58:01 +01:00
build build: add script to find commits suitable for cherry picking 2021-07-01 21:13:56 +02:00
collections luci-lib-docker: add container export support 2021-06-16 14:52:05 +02:00
contrib/package csstidy: update to latest Git HEAD 2021-06-13 19:56:32 +02:00
docs docs: update js api docs 2020-08-06 17:58:47 +02:00
libs rpcd-mod-luci: parse prefix size from DHCPv6 leases 2021-10-26 19:41:04 +02:00
modules luci-base: properly handle promise targets in Request.request() 2022-02-21 15:06:41 +01:00
protocols protocols: make APN option optional again 2022-02-16 00:34:28 +01:00
themes luci-theme-bootstrap: fix style quirk introduced by backport 2022-02-16 10:49:33 +01:00
.gitignore luci-base: add support for plural translations and contexts in Lua api 2020-01-25 23:21:35 +01:00
CONTRIBUTING.md CONTRIBUTING.md: Fix sign_your_work link. 2020-03-01 14:33:20 -08:00
jsdoc.conf.json docs: various updates 2019-11-07 12:39:24 +01:00
LICENSE * new project: ff-luci - Freifunk Lua Configuration Interface 2008-03-02 21:52:58 +00:00
luci.mk translation: add Danish to luci.mk 2021-11-20 10:22:39 +02:00
NOTICE Update my email addresses in the license headers 2015-01-16 23:49:44 +01:00
package.json docs: various updates 2019-11-07 12:39:24 +01:00
README.md docs: various updates 2019-11-07 12:39:24 +01:00

OpenWrt luci feed

Translation status

Description

This is the OpenWrt "luci"-feed containing LuCI - OpenWrt Configuration Interface.

Usage

This feed is enabled by default. Your feeds.conf.default (or feeds.conf) should contain a line like:

src-git luci https://github.com/openwrt/luci.git

To install all its package definitions, run:

./scripts/feeds update luci
./scripts/feeds install -a -p luci

API Reference

You can browse the generated API documentation directly on Github.

Development

Documentation for developing and extending LuCI can be found in the Wiki

License

See LICENSE file.

Package Guidelines

See CONTRIBUTING.md file.

Translation status

Translation status