← Back to team overview

mahara-contributors team mailing list archive

[Bug 1826937] [NEW] Deleting comment in artefact view causes undefined property error

 

Public bug reported:

[WAR] 7e (artefact/comment/lib.php:1465) Trying to get property of non-object
Call stack (most recent first):

    log_message("Trying to get property of non-object", 8, true, true, "/home/robertl/code/mahara-devel/mahara/htdocs/arte...", 1465) at /home/robertl/code/mahara-devel/mahara/htdocs/lib/errors.php:520
    error(8, "Trying to get property of non-object", "/home/robertl/code/mahara-devel/mahara/htdocs/arte...", 1465, array(size 13)) at /home/robertl/code/mahara-devel/mahara/htdocs/artefact/comment/lib.php:1465
    delete_comment_submit(object(Pieform), array(size 3)) at /home/robertl/code/mahara-devel/mahara/htdocs/lib/pieforms/pieform.php:544

This is because we are checking the view id rather than the artefact id
the comment is attached to

To replicate:

1. Create 2 users.
2. Log in as user A and create a page containing an image block
3. Shared page with user B.
4. Log in as user B and comment on the image block.
5. Delete the comment.

** Affects: mahara
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of Mahara
Contributors, which is subscribed to Mahara.
Matching subscriptions: Subscription for all Mahara Contributors -- please ask on #mahara-dev or mahara.org forum before editing or unsubscribing it!
https://bugs.launchpad.net/bugs/1826937

Title:
  Deleting comment in artefact view causes undefined property error

Status in Mahara:
  New

Bug description:
  [WAR] 7e (artefact/comment/lib.php:1465) Trying to get property of non-object
  Call stack (most recent first):

      log_message("Trying to get property of non-object", 8, true, true, "/home/robertl/code/mahara-devel/mahara/htdocs/arte...", 1465) at /home/robertl/code/mahara-devel/mahara/htdocs/lib/errors.php:520
      error(8, "Trying to get property of non-object", "/home/robertl/code/mahara-devel/mahara/htdocs/arte...", 1465, array(size 13)) at /home/robertl/code/mahara-devel/mahara/htdocs/artefact/comment/lib.php:1465
      delete_comment_submit(object(Pieform), array(size 3)) at /home/robertl/code/mahara-devel/mahara/htdocs/lib/pieforms/pieform.php:544

  This is because we are checking the view id rather than the artefact
  id the comment is attached to

  To replicate:

  1. Create 2 users.
  2. Log in as user A and create a page containing an image block
  3. Shared page with user B.
  4. Log in as user B and comment on the image block.
  5. Delete the comment.

To manage notifications about this bug go to:
https://bugs.launchpad.net/mahara/+bug/1826937/+subscriptions


Follow ups