diff --git a/src/applications/diffusion/conduit/DiffusionGetRecentCommitsByPathConduitAPIMethod.php b/src/applications/diffusion/conduit/DiffusionGetRecentCommitsByPathConduitAPIMethod.php
--- a/src/applications/diffusion/conduit/DiffusionGetRecentCommitsByPathConduitAPIMethod.php
+++ b/src/applications/diffusion/conduit/DiffusionGetRecentCommitsByPathConduitAPIMethod.php
@@ -23,6 +23,12 @@
     );
   }
 
+  protected function defineErrorTypes() {
+    return array(
+      'ERR_NOT_FOUND' => pht('Repository was not found.'),
+    );
+  }
+
   protected function defineReturnType() {
     return 'nonempty list<string>';
   }
@@ -36,6 +42,10 @@
         'branch' => $request->getValue('branch'),
       ));
 
+    if ($drequest === null) {
+        throw new ConduitException('ERR_NOT_FOUND');
+    }
+
     $limit = nonempty(
       $request->getValue('limit'),
       self::DEFAULT_LIMIT);