what exactly is going on with this javascript statement:
var loadPrevious = (loadPrevious || function() {});
From my understanding, the variable loadPrevious is either going to be an anonymous function or the value loadPrevious
EDIT:
ok great thanks for the answers and comments. But why then would there be a statement like this:
var app;
loadPrevious(app = launchApplication($("#target"),0));
what does loadPrevious do here? And why do it this way?
it checks to see if loadPrevious has already been assigned a value. if not, it assigns it an empty function.
this syntax is the javascript equivalent of the C++ or C# ternary syntax
in C#, for example.