diff --git a/helpers/Dojo/DojoBackendHelper.ts b/helpers/Dojo/DojoBackendHelper.ts
index b201276faef6eae814dcbff93f7c0325eea20d32..7475376fb003f3661e1363f3c437098b04ad6082 100644
--- a/helpers/Dojo/DojoBackendHelper.ts
+++ b/helpers/Dojo/DojoBackendHelper.ts
@@ -4,19 +4,19 @@ import ClientsSharedConfig from '../../config/ClientsSharedConfig.js';
 
 class DojoBackendHelper {
     public getApiUrl(route: ApiRoute, options?: Partial<{ assignmentNameOrUrl: string, exerciseIdOrUrl: string, gitlabProjectId: string }>): string {
-        const url = `${ ClientsSharedConfig.apiURL }${ route }`;
+        let url = `${ ClientsSharedConfig.apiURL }${ route }`;
 
         if ( options ) {
             if ( options.assignmentNameOrUrl ) {
-                return url.replace('{{assignmentNameOrUrl}}', encodeURIComponent(options.assignmentNameOrUrl));
+                url = url.replace('{{assignmentNameOrUrl}}', encodeURIComponent(options.assignmentNameOrUrl));
             }
 
             if ( options.exerciseIdOrUrl ) {
-                return url.replace('{{exerciseIdOrUrl}}', encodeURIComponent(options.exerciseIdOrUrl));
+                url = url.replace('{{exerciseIdOrUrl}}', encodeURIComponent(options.exerciseIdOrUrl));
             }
 
             if ( options.gitlabProjectId ) {
-                return url.replace('{{gitlabProjectId}}', encodeURIComponent(options.gitlabProjectId));
+                url = url.replace('{{gitlabProjectId}}', encodeURIComponent(options.gitlabProjectId));
             }
         }