Update calendar.js

Some small fix on edit an existing calendar. The old active variable checked the length of an checkbox ... so the return value was "2". Make this sense? Here's the fix!
Merge pull request #215 from libasys/patch-3

Update calendar.js