Minutes between 2 dates
<p><code>obj.date</code> is a unix timestamp(long). I've checked that the date is correct, but I can't manage to get the difference in minutes between my two date objects. For example, I get 4, when I'm expecting something close to 30. Why is that?</p>

<pre><code>Date now = new Date();
Date then = new Date((long)obj.date*1000);

int secondsbetweendates = (int) ((then.getTime()-now.getTime())/1000);

int minutesbetweendates = (secondsbetweendates/1000) % 60;
</code></pre>
