luci-base: dhcp.js: allow hostname to be "*"

Fixes: #4430
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
This commit is contained in:
Jo-Philipp Wich 2020-09-16 10:23:35 +02:00
parent 4cdad94c87
commit bdcd094963

View file

@ -20,7 +20,7 @@ return network.registerProtocol('dhcp', {
var dev = this.getL2Device() || this.getDevice(), o;
o = s.taboption('general', form.Value, 'hostname', _('Hostname to send when requesting DHCP'));
o.datatype = 'hostname';
o.datatype = 'or(hostname, "*")';
o.load = function(section_id) {
return callFileRead('/proc/sys/kernel/hostname').then(L.bind(function(hostname) {
this.placeholder = hostname;