From 8b409dfe2ad634b84dcbcc54cdd668488318e79b Mon Sep 17 00:00:00 2001
From: Tom Needham <needham.thomas@gmail.com>
Date: Thu, 13 Sep 2012 14:15:04 +0000
Subject: [PATCH] API: Default to user authentication level

---
 lib/public/api.php | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/lib/public/api.php b/lib/public/api.php
index ed1f6ef237..2821554229 100644
--- a/lib/public/api.php
+++ b/lib/public/api.php
@@ -33,9 +33,10 @@ class API {
 	* @param string $url the url to match
 	* @param callable $action the function to run
 	* @param string $app the id of the app registering the call
+	* @param int $authlevel the level of authentication required for the call (See OC_API constants)
 	*/
-	public static function register($method, $url, $action, $app){
-		\OC_API::register($method, $url, $action, $app);
+	public static function register($method, $url, $action, $app, $authlevel = OC_API::USER_AUTH){
+		\OC_API::register($method, $url, $action, $app, $authlevel);
 	}
      
 }
-- 
GitLab