Method view_has_token uses uninitialized variable

Bug #1281121 reported by Robert Boloc
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Mahara
Fix Released
Low
Robert Lyon

Bug Description

This method is found in htdocs/lib/mahara.php staring on line 2089.

The bug is that it uses a variable ($visible) that does not exist in the function context.

I attach a patch with the fix.

Revision history for this message
Robert Boloc (robertboloc) wrote :
Revision history for this message
Mahara Bot (dev-mahara) wrote : A patch has been submitted for review

Patch for "master" branch: https://reviews.mahara.org/3058

Revision history for this message
Mahara Bot (dev-mahara) wrote :

Patch for "master" branch: https://reviews.mahara.org/3059

Revision history for this message
Mahara Bot (dev-mahara) wrote : A change has been merged

Reviewed: https://reviews.mahara.org/3058
Committed: http://gitorious.org/mahara/mahara/commit/84dfa408e62eec0f3c51002718b7394d0c60f6c2
Submitter: Son Nguyen (<email address hidden>)
Branch: master

commit 84dfa408e62eec0f3c51002718b7394d0c60f6c2
Author: Robert Boloc <email address hidden>
Date: Mon Mar 3 07:44:43 2014 +1300

The $anonfeedback variable has not been used since v1.2 (Bug 1281121)

The only place that calls the get_view_from_token() does nothing with
the output. It is left over code from version 1.2 where the token was
checked to see if an anonymous user could add feedback to a view or
artefact.

The code changed completely in v1.3 where things like tutors came into
play so I've removed the legacy old code from view/artefact.php

Change-Id: Id1bf9732d87d4ac50ab2d12d1279b400d5f6ee30
Signed-off-by: Robert Lyon <email address hidden>

Aaron Wells (u-aaronw)
Changed in mahara:
milestone: none → 1.9.0
importance: Undecided → Low
status: New → Fix Committed
assignee: nobody → Robert Lyon (robertl-9)
Revision history for this message
Aaron Wells (u-aaronw) wrote :

Hi Robert Boloc,

I'm putting together the release notes for Mahara 1.9.0. In the release announcement, we like to give credit to which institutions the developers work for. Do you have an institutional affiliation (i.e. employer or university) that you want this patch credited to? Or are you fine with crediting it to "Unaffiliated"?

(For an example, here's the 1.8.0 release announcement, with the list of developers' employers: https://mahara.org/interaction/forum/topic.php?id=5833#post24914 )

Cheers,
Aaron

Revision history for this message
Robert Boloc (robertboloc) wrote : Re: [Bug 1281121] Re: Method view_has_token uses uninitialized variable

Hi Aaron,

I work for the Rovira i Virgili University so this can be used as my
affiliation.

Thank you.

Regards,
Robert
El 14/04/2014 04:15, "Aaron Wells" <email address hidden> escribió:

> Hi Robert Boloc,
>
> I'm putting together the release notes for Mahara 1.9.0. In the release
> announcement, we like to give credit to which institutions the
> developers work for. Do you have an institutional affiliation (i.e.
> employer or university) that you want this patch credited to? Or are you
> fine with crediting it to "Unaffiliated"?
>
> (For an example, here's the 1.8.0 release announcement, with the list of
> developers' employers:
> https://mahara.org/interaction/forum/topic.php?id=5833#post24914 )
>
> Cheers,
> Aaron
>
> --
> You received this bug notification because you are subscribed to the bug
> report.
> https://bugs.launchpad.net/bugs/1281121
>
> Title:
> Method view_has_token uses uninitialized variable
>
> Status in Mahara ePortfolio:
> Fix Committed
>
> Bug description:
> This method is found in htdocs/lib/mahara.php staring on line 2089.
>
> The bug is that it uses a variable ($visible) that does not exist in
> the function context.
>
> I attach a patch with the fix.
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/mahara/+bug/1281121/+subscriptions
>

Robert Lyon (robertl-9)
Changed in mahara:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.