Message from JavaScript discussions

December 2016

— Usually var gives context to literals

— 

So if I give my variable declaration as an operand of the ternary, it would work, as well as using Object()

— 

var selected = idnum ? new Object({uris: [state.itemEntryContainer[idnum].uri]}) : state.itemEntryContainer.list();

works :)

Message permanent page

— Turns out I was writing the ternary wrong the entire time

— Haha, why?

— I swapped the colon and question mark

— 

conditional : iftrue ? iffalse

= wrong

— 

conditional ? iftrue : iffalse

= right

— But a few days ago you wrote it right

— I wrote it right in chat!

— Haha

— Lmao 😂