mirror of
https://github.com/Ylianst/MeshAgent
synced 2026-01-03 00:53:41 +00:00
Updated, so if the named key is null, the default value will be set instead.
This commit is contained in:
File diff suppressed because one or more lines are too long
@@ -181,7 +181,7 @@ function windows_registry()
|
||||
break;
|
||||
}
|
||||
|
||||
if (this._AdvApi.RegSetValueExW(h.Deref(), this._marshal.CreateVariable(key, { wide: true }), 0, dataType, data, data._size).Val != 0)
|
||||
if (this._AdvApi.RegSetValueExW(h.Deref(), key?this._marshal.CreateVariable(key, { wide: true }):0, 0, dataType, data, data._size).Val != 0)
|
||||
{
|
||||
this._AdvApi.RegCloseKey(h.Deref());
|
||||
throw ('Error writing reg key: ' + key);
|
||||
|
||||
Reference in New Issue
Block a user