calling _get_cli_params() when no params present needs fixing

Bug #1394754 reported by Robert Lyon on 2014-11-20
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Mahara
Low
Robert Lyon

Bug Description

Noticed this when testing something else

The _get_cli_params() function doesn't check if there are argv options before trying to array_search/array_slice/foreach them

need to wrap it in a if (!empty($options)) { }

Tags: cli Edit Tag help
Robert Lyon (robertl-9) on 2014-11-20
Changed in mahara:
status: New → In Progress
importance: Undecided → Low
assignee: nobody → Robert Lyon (robertl-9)
milestone: none → 15.04.0

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

commit 0a547afc60d4a88d5b91ad8b61d1d66f9661e56c
Author: Robert Lyon <email address hidden>
Date: Fri Nov 21 10:20:28 2014 +1300

Making sure options exist for _get_cli_params() (Bug 1394754)

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

Changed in mahara:
status: In Progress → Fix Committed
Mahara Bot (dev-mahara) wrote :

Reviewed: https://reviews.mahara.org/4020
Committed: http://gitorious.org/mahara/mahara/commit/7a4429ec540115d90da3925e4ba73021e52cc80f
Submitter: Robert Lyon (<email address hidden>)
Branch: 1.10_STABLE

commit 7a4429ec540115d90da3925e4ba73021e52cc80f
Author: Robert Lyon <email address hidden>
Date: Fri Nov 21 10:20:28 2014 +1300

Making sure options exist for _get_cli_params() (Bug 1394754)

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

Aaron Wells (u-aaronw) on 2015-03-03
tags: added: cli
Robert Lyon (robertl-9) on 2015-04-17
Changed in mahara:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers