Skip to content
This repository

Validate before assignation to avoid PHP notice. #46

Open
wants to merge 1 commit into from

1 participant

Juan Uicich
Juan Uicich

No description provided.

Daniel Ziegenberg ziegenberg referenced this pull request from a commit in ziegenberg/wp-recaptcha April 01, 2013
Daniel Ziegenberg Closes #46 and #47 of official issue list 21b72ef
Andrew ace-dent referenced this pull request from a commit in ace-dent/wp-recaptcha January 30, 2014
Bugfix: PR46 - Avoid PHP notice
Validate before assignation to avoid PHP notice. #46
blaenk#46

Signed-off-by: Andrew <macbook-131@macbook-131s-MacBook-Pro.local>
d151a23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Showing 1 unique commit by 1 author.

Apr 22, 2012
Juan Uicich Validate before assignation to avoid PHP notice. 566c2dd
This page is out of date. Refresh to see the latest.

Showing 1 changed file with 4 additions and 4 deletions. Show diff stats Hide diff stats

  1. 8  recaptcha.php
8  recaptcha.php
@@ -478,12 +478,12 @@ function saved_comment() {
478 478
             if (!is_single() && !is_page())
479 479
                 return;
480 480
             
  481
+            if (empty($_REQUEST['rcommentid']) || empty($_REQUEST['rchash']))
  482
+               return;            
  483
+
481 484
             $comment_id = $_REQUEST['rcommentid'];
482 485
             $comment_hash = $_REQUEST['rchash'];
483  
-            
484  
-            if (empty($comment_id) || empty($comment_hash))
485  
-               return;
486  
-            
  486
+                        
487 487
             if ($comment_hash == $this->hash_comment($comment_id)) {
488 488
                $comment = get_comment($comment_id);
489 489
 
Commit_comment_tip

Tip: You can add notes to lines in a file. Hover to the left of a line to make a note

Something went wrong with that request. Please try again.