diff --git a/lib/Controller/PrinterController.php b/lib/Controller/PrinterController.php index 865e32a..e390408 100644 --- a/lib/Controller/PrinterController.php +++ b/lib/Controller/PrinterController.php @@ -29,7 +29,7 @@ class PrinterController extends Controller { public function printfile($sourcefile, $orientation) { if($orientation === "landscape") { $filefullpath = \OC\Files\Filesystem::getLocalFile($sourcefile); - exec('sudo lpr "' . $filefullpath . '"'); + exec('lpr "' . $filefullpath . '"'); return new JSONResponse( array( 'response' => 'success', @@ -40,7 +40,7 @@ class PrinterController extends Controller { if($orientation === "portrait"){ $filefullpath = \OC\Files\Filesystem::getLocalFile($sourcefile); - exec('sudo lpr -o orientation-requested=4 "' . $filefullpath . '"'); + exec('lpr -o orientation-requested=4 "' . $filefullpath . '"'); return new JSONResponse( array( 'response' => 'success',