So my problem is the following:
I have the two functions
getDatesAndStringOfTimespan(timeSpan, goBack) returns {from, to}
limitFromAndTo(from, to, fromLimit, toLimit) returns {from, to}
I now want to do the following:
let { from, to } = getDatesAndStringOfTimespan(timeSpan, goBack)
{ from, to } = limitFromAndTo(from, to, fromLimit, toLimit)
But it says 'Declaration or statement expected.' I know I could do
let { from, to } = getDatesAndStringOfTimespan(timeSpan, goBack)
let object = limitFromAndTo(from, to, fromLimit, toLimit)
from = object.from
to = object.to
It just seems like there is a smarter way of doing this.