Skip to content

Commit

Permalink
Extend Microsoft plugins for LTI project
Browse files Browse the repository at this point in the history
  • Loading branch information
weilai-irl committed Mar 23, 2022
1 parent cb5eada commit 79ce7e0
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions classes/utils.php
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,8 @@ class utils {
*/
public static function process_json_response($response, array $expectedstructure = array()) {
$backtrace = debug_backtrace(0);
$callingclass = (isset($backtrace[1]['class'])) ? $backtrace[1]['class'] : '?';
$callingfunc = (isset($backtrace[1]['function'])) ? $backtrace[1]['function'] : '?';
$callingline = (isset($backtrace[0]['line'])) ? $backtrace[0]['line'] : '?';
$caller = $callingclass.'::'.$callingfunc.':'.$callingline;
$caller = __METHOD__ . ':' . $callingline;

$result = @json_decode($response, true);
if (empty($result) || !is_array($result)) {
Expand Down

0 comments on commit 79ce7e0

Please sign in to comment.