Merge branch 'master' into master
This commit is contained in:
@@ -9,7 +9,7 @@ use Symfony\Component\Console\Input\InputArgument;
|
||||
use Symfony\Component\Console\Input\InputInterface;
|
||||
use Symfony\Component\Console\Output\OutputInterface;
|
||||
|
||||
class Aria2Command extends base
|
||||
class Aria2Command extends Base
|
||||
{
|
||||
public function __construct()
|
||||
{
|
||||
|
||||
@@ -186,7 +186,7 @@ class Aria2Controller extends Controller
|
||||
if ($row = $this->dbconn->getByGid($gid)) {
|
||||
$filename = $row['filename'];
|
||||
$timestamp = $row['timestamp'];
|
||||
$extra = unserialize($row['data']);
|
||||
$extra = $this->dbconn->getExtra(($row['data']));
|
||||
} else if (isset($value['files'][0]['path'])) {
|
||||
$parts = explode("/", ($path = $value['files'][0]['path']));
|
||||
if (count($parts) > 1) {
|
||||
|
||||
@@ -32,7 +32,6 @@ class MainController extends Controller
|
||||
$this->uid = $UserId;
|
||||
$this->l10n = $IL10N;
|
||||
//$this->rootFolder = $rootFolder;
|
||||
OC_Util::setupFS();
|
||||
$this->aria2 = $aria2;
|
||||
$this->aria2->init();
|
||||
$this->urlGenerator = \OC::$server->getURLGenerator();
|
||||
|
||||
@@ -17,6 +17,7 @@ class YoutubeHelper
|
||||
public $file = null;
|
||||
public $filesize = null;
|
||||
protected $pid = 0;
|
||||
private static $instance = null;
|
||||
public function __construct()
|
||||
{
|
||||
$this->dbconn = new DbHelper();
|
||||
@@ -26,7 +27,12 @@ class YoutubeHelper
|
||||
|
||||
public static function create()
|
||||
{
|
||||
return new static();
|
||||
|
||||
if (!self::$instance) {
|
||||
self::$instance = new static();
|
||||
}
|
||||
|
||||
return self::$instance;
|
||||
}
|
||||
public function getFilePath($output)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user