can3p (can3p) wrote in changelog,
can3p
can3p
changelog

[livejournal] r22365: LJSUP-12776: Can't change time of entry ...

Committer: dpetrov
LJSUP-12776: Can't change time of entry on Alpha
U   trunk/htdocs/js/jquery/jquery.lj.entryDatePicker.js
Modified: trunk/htdocs/js/jquery/jquery.lj.entryDatePicker.js
===================================================================
--- trunk/htdocs/js/jquery/jquery.lj.entryDatePicker.js	2012-07-02 12:05:33 UTC (rev 22364)
+++ trunk/htdocs/js/jquery/jquery.lj.entryDatePicker.js	2012-07-02 14:05:53 UTC (rev 22365)
@@ -301,17 +301,18 @@
 				return;
 			}
 
-			var current = new Date();
+			var current = new Date(),
+				toSet = new Date(date);
 			current.setMilliseconds(0);
 			current.setSeconds(0);
 			current.setMinutes(0);
 			current.setHours(0);
-			date.setMilliseconds(0);
-			date.setSeconds(0);
-			date.setMinutes(0);
-			date.setHours(0);
+			toSet.setMilliseconds(0);
+			toSet.setSeconds(0);
+			toSet.setMinutes(0);
+			toSet.setHours(0);
 
-			var delta = +date - (+new Date());
+			var delta = +toSet - (+new Date());
 			this._setTime(date);
 
 			if (delta > 0) {

Tags: can3p, dpetrov, js, livejournal
Subscribe
  • Post a new comment

    Error

    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded 

  • 0 comments