Skip to content

Commit

Permalink
DML fix
Browse files Browse the repository at this point in the history
  • Loading branch information
skodak committed Mar 28, 2009
1 parent add560f commit b7bad38
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions repository/ws.php
Original file line number Diff line number Diff line change
Expand Up @@ -84,8 +84,8 @@

/// Get repository instance information
$sql = 'SELECT i.name, i.typeid, r.type FROM {repository} r, {repository_instances} i '.
'WHERE i.id='.$repo_id.' AND i.typeid=r.id';
if (!$repository = $DB->get_record_sql($sql)) {
'WHERE i.id=? AND i.typeid=r.id';
if (!$repository = $DB->get_record_sql($sql, array($repo_id))) {
$err = new stdclass;
$err->e = get_string('invalidrepositoryid', 'repository');
die(json_encode($err));
Expand Down

0 comments on commit b7bad38

Please sign in to comment.