Merge pull request #670 from radiorabe/dev/zf1s

Use zf1s packages to gain php 7.2 compatibility
This commit is contained in:
Robb 2019-01-20 16:21:28 -05:00 committed by GitHub
commit 17e69cf0fa
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 1684 additions and 67 deletions

View file

@ -64,10 +64,10 @@ set_include_path(APPLICATION_PATH . '/common/' . PATH_SEPARATOR . get_include_pa
require_once 'autoload.php';
/** Zend_Application */
require_once 'Zend/Application.php';
$application = new Zend_Application(
APPLICATION_ENV,
CONFIG_PATH . 'application.ini'
CONFIG_PATH . 'application.ini',
true
);
require_once(APPLICATION_PATH . "logging/Logging.php");

View file

@ -130,7 +130,8 @@ class Rest_MediaController extends Zend_Rest_Controller
try {
// REST uploads are not from Zend_Form, hence we handle them using Zend_File_transfer directly
$upload = new Zend_File_Transfer();
// we need to specify an explicit adapter since autodetection broke in php 7.2
$upload = new Zend_File_Transfer('Zend_File_Transfer_Adapter_Http');
// this error should not really get hit, letting the user know if it does is nice for debugging
// see: https://github.com/LibreTime/libretime/issues/3#issuecomment-281143417
if (!$upload->isValid('file')) {