Skip to content

Commit

Permalink
[API] Add support for project name with space (aces#7463)
Browse files Browse the repository at this point in the history
Handle project names which need to be URL encoded in the API, such as projects with spaces.
  • Loading branch information
laemtl authored and AlexandraLivadas committed Jun 29, 2021
1 parent 86adf7e commit 2bca6b6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion modules/api/php/endpoints/projects.class.inc
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ class Projects extends Endpoint implements \LORIS\Middleware\ETagCalculator

// Delegate to project specific endpoint.
try {
$project_name = $pathparts[1] ?? '';
$project_name = urldecode($pathparts[1] ?? '');
$project = \NDB_Factory::singleton()
->project($project_name);
} catch (\NotFound $e) {
Expand Down

0 comments on commit 2bca6b6

Please sign in to comment.