From a76f0a0ba7e170a0fe5404fc43cc83c3a2dc2240 Mon Sep 17 00:00:00 2001
From: Vincent Petry <pvince81@owncloud.com>
Date: Thu, 15 Jan 2015 18:45:24 +0100
Subject: [PATCH] Fix preview route for trashbin

---
 apps/files_trashbin/appinfo/routes.php | 7 ++-----
 1 file changed, 2 insertions(+), 5 deletions(-)

diff --git a/apps/files_trashbin/appinfo/routes.php b/apps/files_trashbin/appinfo/routes.php
index 56dbf38273..66a324c54d 100644
--- a/apps/files_trashbin/appinfo/routes.php
+++ b/apps/files_trashbin/appinfo/routes.php
@@ -1,10 +1,7 @@
 <?php
 /** @var $this \OCP\Route\IRouter */
-$this->create('core_ajax_trashbin_preview', '/preview')->action(
-function() {
-	require_once __DIR__ . '/../ajax/preview.php';
-});
-
+$this->create('core_ajax_trashbin_preview', 'ajax/preview.php')
+	->actionInclude('files_trashbin/ajax/preview.php');
 $this->create('files_trashbin_ajax_delete', 'ajax/delete.php')
 	->actionInclude('files_trashbin/ajax/delete.php');
 $this->create('files_trashbin_ajax_isEmpty', 'ajax/isEmpty.php')
-- 
GitLab