Closed klein0r closed 2 years ago
Because it never worksed withnull as first param I think option 1 makes sense inl adjusting docs
I would test it - but every release since 5.7.0 failed and was not published.
https://github.com/ioBroker/ioBroker.javascript/runs/7186405290
I had the same problem with the build process in #1052
Tested with 5.8.5 ✅
Describe the bug
Documentation tells me, that I can use
writeFile
without the first parameterhttps://github.com/ioBroker/ioBroker.javascript/blob/d3b21372e1789ea607612bcacb1ef7300e45f386/docs/en/javascript.md?plain=1#L1258-L1262
But: This will not work, because the adapter class will use the adapter name as first parameter (meta object) when value is null. Test Script:
Error
Solution 1
Update the
writeFile
function in the sandbox, which setsadapter = '0_userdata.0'
when adapter is null, because0_userdata.0
is already an existing object of type meta. Plus: Files created in this meta storage will be visible in the files section of admin.Solution 2
javascript.<instance>
(like vis or admin)adapter
parameter tothis.namespace
when null.Solution 3
Remove that information from documentation 😄
Versions: