Keep data from jquery getjson
<p>I have this code:</p>

<pre><code>$.getJSON(fupurl, function(data) {
       ups = data[url+forup].shares;
        console.log(ups);
    });
$.getJSON(fdownurl, function(data) {
       downs = data[url+fordown].shares;
       if(!downs)
       downs = 0;
        console.log(downs);
    });
console.log(ups);
</code></pre>

<p>The above code it's inside of a function and variables downs and ups are defined before it.
I want to keep data inside those two variables to use it later.</p>
