Don't want to lose these files

This commit is contained in:
nelsonlaquet 2013-09-01 19:11:33 -05:00
parent 1617b605f6
commit 84f6064a1b
12 changed files with 442 additions and 125 deletions

View file

@ -7,6 +7,7 @@
use Commands\UploadTrackCommand; use Commands\UploadTrackCommand;
use Cover; use Cover;
use Entities\Image; use Entities\Image;
use Entities\News;
use Entities\Track; use Entities\Track;
use Illuminate\Support\Facades\Auth; use Illuminate\Support\Facades\Auth;
use Illuminate\Support\Facades\Input; use Illuminate\Support\Facades\Input;
@ -30,6 +31,7 @@
return Response::json([ return Response::json([
'recent_tracks' => $recentTracks, 'recent_tracks' => $recentTracks,
'popular_tracks' => Track::popular(30, Auth::check() && Auth::user()->can_see_explicit_content)], 200); 'popular_tracks' => Track::popular(30, Auth::check() && Auth::user()->can_see_explicit_content),
'news' => News::getNews(0, 10)], 200);
} }
} }

View file

@ -0,0 +1,21 @@
<?php
use Illuminate\Database\Migrations\Migration;
class CreateNewsTable extends Migration {
public function up() {
Schema::create('news', function($table){
$table->increments('id');
$table->integer('user_id')->unsigned()->index();
$table->string('post_hash', 32)->index();
$table->timestamps();
$table->foreign('user_id')->references('id')->on('users')->onDelete('cascade');
});
}
public function down() {
Schema::drop('news');
}
}

View file

@ -40,7 +40,7 @@
}); });
App::error(function($exception) { App::error(function($exception) {
return Response::view('errors.500', array(), 404); // return Response::view('errors.500', array(), 404);
}); });
} }

View file

@ -0,0 +1,59 @@
<?php
namespace Entities;
use Illuminate\Support\Facades\Auth;
use SimplePie;
class News extends \Eloquent {
public static function getNews($start = 0, $end = 4) {
$feed = new SimplePie();
$feed->cache = false;
$feed->set_feed_url('http://mlpforums.com/blog/rss/404-ponyfm-development-blog/');
$feed->init();
$feed->handle_content_type();
$posts = $feed->get_items($start, $end);
$postHashes = [];
foreach ($posts as $post) {
$postHashes[] = self::calculateHash($post->get_permalink());
}
$seenRecords = self::where('user_id', '=', Auth::user()->id)->whereIn('post_hash', $postHashes)->get();
$seenHashes = [];
foreach ($seenRecords as $record) {
$seenHashes[$record->post_hash] = 1;
}
$postsReturn = [];
// This date is around when the last blog post was posted as of now.
// I put in a cutoff so that blog posts made before this update is pushed are always marked as 'read'
$readCutoffDate = mktime(null, null, null, 4, 28, 2013);
foreach ($posts as $post) {
$autoRead = $post->get_date('U') < $readCutoffDate;
$postsReturn[] = [
'post' => [
'title' => $post->get_title(),
'date' => $post->get_date('j F Y g:i a'),
'url' => $post->get_permalink()
],
'read' => $autoRead || isset($seenHashes[self::calculateHash($post->get_permalink())])];
}
return $postsReturn;
}
public static function markPostAsRead($postUrl) {
$postHash = self::calculateHash($postUrl);
$news = News::create(['user_id' => Auth::user()->id, 'post_hash' => $postHash]);
$news->save();
}
private static function calculateHash($postPermalink) {
return md5($postPermalink);
}
}

View file

@ -183,7 +183,7 @@ class Container implements ArrayAccess
if (is_null($dependency)) { if (is_null($dependency)) {
$dependencies[] = $this->resolveNonClass($parameter); $dependencies[] = $this->resolveNonClass($parameter);
} else { } else {
$dependencies[] = $this->make($dependency->name); $dependencies[] = $this->resolveClass($parameter);
} }
} }
return (array) $dependencies; return (array) $dependencies;
@ -197,6 +197,18 @@ class Container implements ArrayAccess
throw new BindingResolutionException($message); throw new BindingResolutionException($message);
} }
} }
protected function resolveClass(ReflectionParameter $parameter)
{
try {
return $this->make($parameter->getClass()->name);
} catch (BindingResolutionException $e) {
if ($parameter->isOptional()) {
return $parameter->getDefaultValue();
} else {
throw $e;
}
}
}
public function resolving(Closure $callback) public function resolving(Closure $callback)
{ {
$this->resolvingCallbacks[] = $callback; $this->resolvingCallbacks[] = $callback;
@ -290,7 +302,7 @@ use Symfony\Component\HttpKernel\Exception\NotFoundHttpException;
use Symfony\Component\HttpFoundation\RedirectResponse as SymfonyRedirect; use Symfony\Component\HttpFoundation\RedirectResponse as SymfonyRedirect;
class Application extends Container implements HttpKernelInterface, ResponsePreparerInterface class Application extends Container implements HttpKernelInterface, ResponsePreparerInterface
{ {
const VERSION = '4.0.2'; const VERSION = '4.0.6';
protected $booted = false; protected $booted = false;
protected $bootingCallbacks = array(); protected $bootingCallbacks = array();
protected $bootedCallbacks = array(); protected $bootedCallbacks = array();
@ -298,6 +310,7 @@ class Application extends Container implements HttpKernelInterface, ResponsePrep
protected $serviceProviders = array(); protected $serviceProviders = array();
protected $loadedProviders = array(); protected $loadedProviders = array();
protected $deferredServices = array(); protected $deferredServices = array();
protected static $requestClass = 'Illuminate\\Http\\Request';
public function __construct(Request $request = null) public function __construct(Request $request = null)
{ {
$this['request'] = $this->createRequest($request); $this['request'] = $this->createRequest($request);
@ -307,12 +320,13 @@ class Application extends Container implements HttpKernelInterface, ResponsePrep
} }
protected function createRequest(Request $request = null) protected function createRequest(Request $request = null)
{ {
return $request ?: Request::createFromGlobals(); return $request ?: static::onRequest('createFromGlobals');
} }
public function setRequestForConsoleEnvironment() public function setRequestForConsoleEnvironment()
{ {
$url = $this['config']->get('app.url', 'http://localhost'); $url = $this['config']->get('app.url', 'http://localhost');
$this->instance('request', Request::create($url, 'GET', array(), array(), array(), $_SERVER)); $parameters = array($url, 'GET', array(), array(), array(), $_SERVER);
$this->instance('request', static::onRequest('create', $parameters));
} }
public function redirectIfTrailingSlash() public function redirectIfTrailingSlash()
{ {
@ -476,10 +490,11 @@ class Application extends Container implements HttpKernelInterface, ResponsePrep
{ {
if ($this->isDownForMaintenance()) { if ($this->isDownForMaintenance()) {
$response = $this['events']->until('illuminate.app.down'); $response = $this['events']->until('illuminate.app.down');
return $this->prepareResponse($response, $request); if (!is_null($response)) {
} else { return $this->prepareResponse($response, $request);
return $this['router']->dispatch($this->prepareRequest($request)); }
} }
return $this['router']->dispatch($this->prepareRequest($request));
} }
public function handle(SymfonyRequest $request, $type = HttpKernelInterface::MASTER_REQUEST, $catch = true) public function handle(SymfonyRequest $request, $type = HttpKernelInterface::MASTER_REQUEST, $catch = true)
{ {
@ -553,7 +568,7 @@ class Application extends Container implements HttpKernelInterface, ResponsePrep
{ {
$this['exception']->error($callback); $this['exception']->error($callback);
} }
public function pushError(Closure $closure) public function pushError(Closure $callback)
{ {
$this['exception']->pushError($callback); $this['exception']->pushError($callback);
} }
@ -586,6 +601,17 @@ class Application extends Container implements HttpKernelInterface, ResponsePrep
{ {
$this->deferredServices = $services; $this->deferredServices = $services;
} }
public static function requestClass($class = null)
{
if (!is_null($class)) {
static::$requestClass = $class;
}
return static::$requestClass;
}
public static function onRequest($method, $parameters = array())
{
return forward_static_call_array(array(static::requestClass(), $method), $parameters);
}
public function __get($key) public function __get($key)
{ {
return $this[$key]; return $this[$key];
@ -665,7 +691,7 @@ class Request extends \Symfony\Component\HttpFoundation\Request
} }
return true; return true;
} }
if (is_array($this->input($key))) { if (is_bool($this->input($key)) or is_array($this->input($key))) {
return true; return true;
} }
return trim((string) $this->input($key)) !== ''; return trim((string) $this->input($key)) !== '';
@ -782,6 +808,15 @@ class Request extends \Symfony\Component\HttpFoundation\Request
$acceptable = $this->getAcceptableContentTypes(); $acceptable = $this->getAcceptableContentTypes();
return isset($acceptable[0]) and $acceptable[0] == 'application/json'; return isset($acceptable[0]) and $acceptable[0] == 'application/json';
} }
public function format($default = 'html')
{
foreach ($this->getAcceptableContentTypes() as $type) {
if ($format = $this->getFormat($type)) {
return $format;
}
}
return $default;
}
public function getSessionStore() public function getSessionStore()
{ {
if (!isset($this->sessionStore)) { if (!isset($this->sessionStore)) {
@ -808,6 +843,8 @@ class Request
const HEADER_CLIENT_PROTO = 'client_proto'; const HEADER_CLIENT_PROTO = 'client_proto';
const HEADER_CLIENT_PORT = 'client_port'; const HEADER_CLIENT_PORT = 'client_port';
protected static $trustedProxies = array(); protected static $trustedProxies = array();
protected static $trustedHostPatterns = array();
protected static $trustedHosts = array();
protected static $trustedHeaders = array(self::HEADER_CLIENT_IP => 'X_FORWARDED_FOR', self::HEADER_CLIENT_HOST => 'X_FORWARDED_HOST', self::HEADER_CLIENT_PROTO => 'X_FORWARDED_PROTO', self::HEADER_CLIENT_PORT => 'X_FORWARDED_PORT'); protected static $trustedHeaders = array(self::HEADER_CLIENT_IP => 'X_FORWARDED_FOR', self::HEADER_CLIENT_HOST => 'X_FORWARDED_HOST', self::HEADER_CLIENT_PROTO => 'X_FORWARDED_PROTO', self::HEADER_CLIENT_PORT => 'X_FORWARDED_PORT');
protected static $httpMethodParameterOverride = false; protected static $httpMethodParameterOverride = false;
public $attributes; public $attributes;
@ -952,6 +989,9 @@ class Request
$dup->basePath = null; $dup->basePath = null;
$dup->method = null; $dup->method = null;
$dup->format = null; $dup->format = null;
if (!$dup->get('_format')) {
$dup->setRequestFormat($this->getRequestFormat());
}
return $dup; return $dup;
} }
public function __clone() public function __clone()
@ -1000,6 +1040,17 @@ class Request
{ {
return self::$trustedProxies; return self::$trustedProxies;
} }
public static function setTrustedHosts(array $hostPatterns)
{
self::$trustedHostPatterns = array_map(function ($hostPattern) {
return sprintf('{%s}i', str_replace('}', '\\}', $hostPattern));
}, $hostPatterns);
self::$trustedHosts = array();
}
public static function getTrustedHosts()
{
return self::$trustedHostPatterns;
}
public static function setTrustedHeaderName($key, $value) public static function setTrustedHeaderName($key, $value)
{ {
if (!array_key_exists($key, self::$trustedHeaders)) { if (!array_key_exists($key, self::$trustedHeaders)) {
@ -1199,7 +1250,19 @@ class Request
} }
$host = strtolower(preg_replace('/:\\d+$/', '', trim($host))); $host = strtolower(preg_replace('/:\\d+$/', '', trim($host)));
if ($host && !preg_match('/^\\[?(?:[a-zA-Z0-9-:\\]_]+\\.?)+$/', $host)) { if ($host && !preg_match('/^\\[?(?:[a-zA-Z0-9-:\\]_]+\\.?)+$/', $host)) {
throw new \UnexpectedValueException('Invalid Host'); throw new \UnexpectedValueException('Invalid Host "' . $host . '"');
}
if (count(self::$trustedHostPatterns) > 0) {
if (in_array($host, self::$trustedHosts)) {
return $host;
}
foreach (self::$trustedHostPatterns as $pattern) {
if (preg_match($pattern, $host)) {
self::$trustedHosts[] = $host;
return $host;
}
}
throw new \UnexpectedValueException('Untrusted Host "' . $host . '"');
} }
return $host; return $host;
} }
@ -2152,7 +2215,18 @@ class NativeSessionStorage implements SessionStorageInterface
if ($destroy) { if ($destroy) {
$this->metadataBag->stampNew(); $this->metadataBag->stampNew();
} }
return session_regenerate_id($destroy); $ret = session_regenerate_id($destroy);
if ('files' === $this->getSaveHandler()->getSaveHandlerName()) {
session_write_close();
if (isset($_SESSION)) {
$backup = $_SESSION;
session_start();
$_SESSION = $backup;
} else {
session_start();
}
}
return $ret;
} }
public function save() public function save()
{ {
@ -3067,7 +3141,7 @@ abstract class ServiceProvider
} }
protected function getClassChain(ReflectionClass $reflect) protected function getClassChain(ReflectionClass $reflect)
{ {
$lastName = null; $classes = array();
while ($reflect !== false) { while ($reflect !== false) {
$classes[] = $reflect; $classes[] = $reflect;
$reflect = $reflect->getParentClass(); $reflect = $reflect->getParentClass();
@ -3081,9 +3155,9 @@ abstract class ServiceProvider
} }
return $namespace; return $namespace;
} }
public function commands() public function commands($commands)
{ {
$commands = func_get_args(); $commands = is_array($commands) ? $commands : func_get_args();
$events = $this->app['events']; $events = $this->app['events'];
$events->listen('artisan.start', function ($artisan) use($commands) { $events->listen('artisan.start', function ($artisan) use($commands) {
$artisan->resolveCommands($commands); $artisan->resolveCommands($commands);
@ -3398,6 +3472,10 @@ class Str
} }
return rtrim($matches[0]) . $end; return rtrim($matches[0]) . $end;
} }
public static function parseCallback($callback, $default)
{
return static::contains($callback, '@') ? explode('@', $callback, 2) : array($callback, $default);
}
public static function plural($value, $count = 2) public static function plural($value, $count = 2)
{ {
return Pluralizer::plural($value, $count); return Pluralizer::plural($value, $count);
@ -3522,6 +3600,9 @@ class ErrorHandler
return true; return true;
} }
if ($this->displayErrors && error_reporting() & $level && $this->level & $level) { if ($this->displayErrors && error_reporting() & $level && $this->level & $level) {
if (!class_exists('Symfony\\Component\\Debug\\Exception\\ContextErrorException')) {
require 'F:\\Nelson\\My Documents - Personal\\Visual Studio 2010\\Projects\\Poniverse\\spa.pony.fm\\vendor\\symfony\\debug\\Symfony\\Component\\Debug' . '/Exception/ContextErrorException.php';
}
throw new ContextErrorException(sprintf('%s: %s in %s line %d', isset($this->levels[$level]) ? $this->levels[$level] : $level, $message, $file, $line), 0, $level, $file, $line, $context); throw new ContextErrorException(sprintf('%s: %s in %s line %d', isset($this->levels[$level]) ? $this->levels[$level] : $level, $message, $file, $line), 0, $level, $file, $line, $context);
} }
return false; return false;
@ -3582,7 +3663,7 @@ class Repository extends NamespacedItemResolver implements ArrayAccess
public function has($key) public function has($key)
{ {
$default = microtime(true); $default = microtime(true);
return $this->get($key, $default) != $default; return $this->get($key, $default) !== $default;
} }
public function hasGroup($key) public function hasGroup($key)
{ {
@ -3923,7 +4004,7 @@ class Filesystem
} }
public function lastModified($path) public function lastModified($path)
{ {
return filemtime(realpath($path)); return filemtime($path);
} }
public function isDirectory($directory) public function isDirectory($directory)
{ {
@ -3959,7 +4040,7 @@ class Filesystem
{ {
$directories = array(); $directories = array();
foreach (Finder::create()->in($directory)->directories()->depth(0) as $dir) { foreach (Finder::create()->in($directory)->directories()->depth(0) as $dir) {
$directories[] = $dir->getRealPath(); $directories[] = $dir->getPathname();
} }
return $directories; return $directories;
} }
@ -3980,12 +4061,12 @@ class Filesystem
foreach ($items as $item) { foreach ($items as $item) {
$target = $destination . '/' . $item->getBasename(); $target = $destination . '/' . $item->getBasename();
if ($item->isDir()) { if ($item->isDir()) {
$path = $item->getRealPath(); $path = $item->getPathname();
if (!$this->copyDirectory($path, $target, $options)) { if (!$this->copyDirectory($path, $target, $options)) {
return false; return false;
} }
} else { } else {
if (!$this->copy($item->getRealPath(), $target)) { if (!$this->copy($item->getPathname(), $target)) {
return false; return false;
} }
} }
@ -4000,9 +4081,9 @@ class Filesystem
$items = new FilesystemIterator($directory); $items = new FilesystemIterator($directory);
foreach ($items as $item) { foreach ($items as $item) {
if ($item->isDir()) { if ($item->isDir()) {
$this->deleteDirectory($item->getRealPath()); $this->deleteDirectory($item->getPathname());
} else { } else {
$this->delete($item->getRealPath()); $this->delete($item->getPathname());
} }
} }
if (!$preserve) { if (!$preserve) {
@ -4248,8 +4329,7 @@ class SessionServiceProvider extends ServiceProvider
} }
protected function registerSessionEvents() protected function registerSessionEvents()
{ {
$app = $this->app; $config = $this->app['config']['session'];
$config = $app['config']['session'];
if (!is_null($config['driver'])) { if (!is_null($config['driver'])) {
$this->registerBootingEvent(); $this->registerBootingEvent();
$this->registerCloseEvent(); $this->registerCloseEvent();
@ -4257,8 +4337,7 @@ class SessionServiceProvider extends ServiceProvider
} }
protected function registerBootingEvent() protected function registerBootingEvent()
{ {
$app = $this->app; $this->app->booting(function ($app) {
$this->app->booting(function ($app) use($app) {
$app['session']->start(); $app['session']->start();
}); });
} }
@ -4286,7 +4365,7 @@ class SessionServiceProvider extends ServiceProvider
{ {
$config = $this->app['config']['session']; $config = $this->app['config']['session'];
$expire = $this->getExpireTime($config); $expire = $this->getExpireTime($config);
setcookie($config['cookie'], session_id(), $expire, $config['path'], $config['domain']); setcookie($config['cookie'], session_id(), $expire, $config['path'], $config['domain'], false, true);
} }
protected function getExpireTime($config) protected function getExpireTime($config)
{ {
@ -4829,21 +4908,21 @@ class Router
$this->patternFilters[$pattern][] = compact('name', 'methods'); $this->patternFilters[$pattern][] = compact('name', 'methods');
} }
} }
public function findPatternFilters(Request $request) public function findPatternFilters($method, $path)
{ {
$results = array(); $results = array();
foreach ($this->patternFilters as $pattern => $filters) { foreach ($this->patternFilters as $pattern => $filters) {
if (str_is('/' . $pattern, $request->getPathInfo())) { if (str_is('/' . $pattern, $path)) {
$merge = $this->filterPatternsByMethod($request, $filters); $merge = $this->filterPatternsByMethod($method, $filters);
$results = array_merge($results, $merge); $results = array_merge($results, $merge);
} }
} }
return $results; return $results;
} }
protected function filterPatternsByMethod(Request $request, $filters) protected function filterPatternsByMethod($method, $filters)
{ {
$results = array(); $results = array();
$method = strtolower($request->getMethod()); $method = strtolower($method);
foreach ($filters as $filter) { foreach ($filters as $filter) {
if (is_null($filter['methods']) or in_array($method, $filter['methods'])) { if (is_null($filter['methods']) or in_array($method, $filter['methods'])) {
$results[] = $filter['name']; $results[] = $filter['name'];
@ -5154,7 +5233,7 @@ class Dispatcher
protected $sorted = array(); protected $sorted = array();
public function __construct(Container $container = null) public function __construct(Container $container = null)
{ {
$this->container = $container; $this->container = $container ?: new Container();
} }
public function listen($event, $listener, $priority = 0) public function listen($event, $listener, $priority = 0)
{ {
@ -5166,7 +5245,7 @@ class Dispatcher
} }
protected function setupWildcardListen($event, $listener, $priority) protected function setupWildcardListen($event, $listener, $priority)
{ {
$this->wildcards[$event][] = $listener; $this->wildcards[$event][] = $this->makeListener($listener);
} }
public function hasListeners($eventName) public function hasListeners($eventName)
{ {
@ -5300,6 +5379,7 @@ abstract class Model implements ArrayAccess, ArrayableInterface, JsonableInterfa
protected $relations = array(); protected $relations = array();
protected $hidden = array(); protected $hidden = array();
protected $visible = array(); protected $visible = array();
protected $appends = array();
protected $fillable = array(); protected $fillable = array();
protected $guarded = array('*'); protected $guarded = array('*');
protected $touches = array(); protected $touches = array();
@ -5376,6 +5456,10 @@ abstract class Model implements ArrayAccess, ArrayableInterface, JsonableInterfa
$model->save(); $model->save();
return $model; return $model;
} }
public static function query()
{
return with(new static())->newQuery();
}
public static function on($connection = null) public static function on($connection = null)
{ {
$instance = new static(); $instance = new static();
@ -5526,7 +5610,8 @@ abstract class Model implements ArrayAccess, ArrayableInterface, JsonableInterfa
{ {
$query = $this->newQuery()->where($this->getKeyName(), $this->getKey()); $query = $this->newQuery()->where($this->getKeyName(), $this->getKey());
if ($this->softDelete) { if ($this->softDelete) {
$query->update(array(static::DELETED_AT => new DateTime())); $this->{static::DELETED_AT} = $time = $this->freshTimestamp();
$query->update(array(static::DELETED_AT => $this->fromDateTime($time)));
} else { } else {
$query->delete(); $query->delete();
} }
@ -5534,8 +5619,13 @@ abstract class Model implements ArrayAccess, ArrayableInterface, JsonableInterfa
public function restore() public function restore()
{ {
if ($this->softDelete) { if ($this->softDelete) {
if ($this->fireModelEvent('restoring') === false) {
return false;
}
$this->{static::DELETED_AT} = null; $this->{static::DELETED_AT} = null;
return $this->save(); $result = $this->save();
$this->fireModelEvent('restored', false);
return $result;
} }
} }
public static function saving($callback) public static function saving($callback)
@ -5570,6 +5660,14 @@ abstract class Model implements ArrayAccess, ArrayableInterface, JsonableInterfa
{ {
static::registerModelEvent('deleted', $callback); static::registerModelEvent('deleted', $callback);
} }
public static function restoring($callback)
{
static::registerModelEvent('restoring', $callback);
}
public static function restored($callback)
{
static::registerModelEvent('restored', $callback);
}
public static function flushEventListeners() public static function flushEventListeners()
{ {
if (!isset(static::$dispatcher)) { if (!isset(static::$dispatcher)) {
@ -5589,7 +5687,7 @@ abstract class Model implements ArrayAccess, ArrayableInterface, JsonableInterfa
} }
public function getObservableEvents() public function getObservableEvents()
{ {
return array('creating', 'created', 'updating', 'updated', 'deleting', 'deleted', 'saving', 'saved'); return array('creating', 'created', 'updating', 'updated', 'deleting', 'deleted', 'saving', 'saved', 'restoring', 'restored');
} }
protected function increment($column, $amount = 1) protected function increment($column, $amount = 1)
{ {
@ -5758,6 +5856,10 @@ abstract class Model implements ArrayAccess, ArrayableInterface, JsonableInterfa
{ {
return new DateTime(); return new DateTime();
} }
public function freshTimestampString()
{
return $this->fromDateTime($this->freshTimestamp());
}
public function newQuery($excludeDeleted = true) public function newQuery($excludeDeleted = true)
{ {
$builder = new Builder($this->newBaseQueryBuilder()); $builder = new Builder($this->newBaseQueryBuilder());
@ -5800,7 +5902,7 @@ abstract class Model implements ArrayAccess, ArrayableInterface, JsonableInterfa
if (isset($this->table)) { if (isset($this->table)) {
return $this->table; return $this->table;
} }
return str_replace('\\', '', snake_case(str_plural(get_class($this)))); return str_replace('\\', '', snake_case(str_plural(class_basename($this))));
} }
public function setTable($table) public function setTable($table)
{ {
@ -5860,6 +5962,10 @@ abstract class Model implements ArrayAccess, ArrayableInterface, JsonableInterfa
{ {
$this->visible = $visible; $this->visible = $visible;
} }
public function setAppends(array $appends)
{
$this->appends = $appends;
}
public function getFillable() public function getFillable()
{ {
return $this->fillable; return $this->fillable;
@ -5941,26 +6047,26 @@ abstract class Model implements ArrayAccess, ArrayableInterface, JsonableInterfa
} }
public function attributesToArray() public function attributesToArray()
{ {
$attributes = $this->getAccessibleAttributes(); $attributes = $this->getArrayableAttributes();
foreach ($this->getMutatedAttributes() as $key) { foreach ($this->getMutatedAttributes() as $key) {
if (!array_key_exists($key, $attributes)) { if (!array_key_exists($key, $attributes)) {
continue; continue;
} }
$attributes[$key] = $this->mutateAttribute($key, $attributes[$key]); $attributes[$key] = $this->mutateAttribute($key, $attributes[$key]);
} }
foreach ($this->appends as $key) {
$attributes[$key] = $this->mutateAttribute($key, null);
}
return $attributes; return $attributes;
} }
protected function getAccessibleAttributes() protected function getArrayableAttributes()
{ {
if (count($this->visible) > 0) { return $this->getArrayableItems($this->attributes);
return array_intersect_key($this->attributes, array_flip($this->visible));
}
return array_diff_key($this->attributes, array_flip($this->hidden));
} }
public function relationsToArray() public function relationsToArray()
{ {
$attributes = array(); $attributes = array();
foreach ($this->relations as $key => $value) { foreach ($this->getArrayableRelations() as $key => $value) {
if (in_array($key, $this->hidden)) { if (in_array($key, $this->hidden)) {
continue; continue;
} }
@ -5972,12 +6078,23 @@ abstract class Model implements ArrayAccess, ArrayableInterface, JsonableInterfa
if (static::$snakeAttributes) { if (static::$snakeAttributes) {
$key = snake_case($key); $key = snake_case($key);
} }
if (isset($relation)) { if (isset($relation) or is_null($value)) {
$attributes[$key] = $relation; $attributes[$key] = $relation;
} }
} }
return $attributes; return $attributes;
} }
protected function getArrayableRelations()
{
return $this->getArrayableItems($this->relations);
}
protected function getArrayableItems(array $values)
{
if (count($this->visible) > 0) {
return array_intersect_key($values, array_flip($this->visible));
}
return array_diff_key($values, array_flip($this->hidden));
}
public function getAttribute($key) public function getAttribute($key)
{ {
$inAttributes = array_key_exists($key, $this->attributes); $inAttributes = array_key_exists($key, $this->attributes);
@ -6039,7 +6156,7 @@ abstract class Model implements ArrayAccess, ArrayableInterface, JsonableInterfa
{ {
return array(static::CREATED_AT, static::UPDATED_AT, static::DELETED_AT); return array(static::CREATED_AT, static::UPDATED_AT, static::DELETED_AT);
} }
protected function fromDateTime($value) public function fromDateTime($value)
{ {
$format = $this->getDateFormat(); $format = $this->getDateFormat();
if ($value instanceof DateTime) { if ($value instanceof DateTime) {
@ -6109,6 +6226,10 @@ abstract class Model implements ArrayAccess, ArrayableInterface, JsonableInterfa
} }
return $dirty; return $dirty;
} }
public function getRelations()
{
return $this->relations;
}
public function getRelation($relation) public function getRelation($relation)
{ {
return $this->relations[$relation]; return $this->relations[$relation];
@ -6134,6 +6255,7 @@ abstract class Model implements ArrayAccess, ArrayableInterface, JsonableInterfa
public function setConnection($name) public function setConnection($name)
{ {
$this->connection = $name; $this->connection = $name;
return $this;
} }
public static function resolveConnection($connection = null) public static function resolveConnection($connection = null)
{ {
@ -6256,6 +6378,7 @@ class DatabaseManager implements ConnectionResolverInterface
} }
public function reconnect($name = null) public function reconnect($name = null)
{ {
$name = $name ?: $this->getDefaultConnection();
unset($this->connections[$name]); unset($this->connections[$name]);
return $this->connection($name); return $this->connection($name);
} }
@ -6265,6 +6388,10 @@ class DatabaseManager implements ConnectionResolverInterface
if (isset($this->extensions[$name])) { if (isset($this->extensions[$name])) {
return call_user_func($this->extensions[$name], $config); return call_user_func($this->extensions[$name], $config);
} }
$driver = $config['driver'];
if (isset($this->extensions[$driver])) {
return call_user_func($this->extensions[$driver], $config);
}
return $this->factory->make($config, $name); return $this->factory->make($config, $name);
} }
protected function prepare(Connection $connection) protected function prepare(Connection $connection)
@ -6409,7 +6536,7 @@ class Store extends SymfonySession
{ {
return array_get($this->all(), $name, $default); return array_get($this->all(), $name, $default);
} }
public function hasOldInput($key) public function hasOldInput($key = null)
{ {
return !is_null($this->getOldInput($key)); return !is_null($this->getOldInput($key));
} }
@ -6543,13 +6670,18 @@ class SessionManager extends Manager
} }
protected function createRedisDriver() protected function createRedisDriver()
{ {
return $this->createCacheBased('redis'); $handler = $this->createCacheHandler('redis');
$handler->getCache()->getStore()->setConnection($this->app['config']['session.connection']);
return $this->buildSession($handler);
} }
protected function createCacheBased($driver) protected function createCacheBased($driver)
{
return $this->buildSession($this->createCacheHandler($driver));
}
protected function createCacheHandler($driver)
{ {
$minutes = $this->app['config']['session.lifetime']; $minutes = $this->app['config']['session.lifetime'];
$handler = new CacheBasedSessionHandler($this->app['cache']->driver($driver), $minutes); return new CacheBasedSessionHandler($this->app['cache']->driver($driver), $minutes);
return $this->buildSession($handler);
} }
protected function buildSession($handler) protected function buildSession($handler)
{ {
@ -6728,11 +6860,15 @@ class Encrypter
if (!$payload or $this->invalidPayload($payload)) { if (!$payload or $this->invalidPayload($payload)) {
throw new DecryptException('Invalid data.'); throw new DecryptException('Invalid data.');
} }
if ($payload['mac'] !== $this->hash($payload['iv'], $payload['value'])) { if (!$this->validMac($payload)) {
throw new DecryptException('MAC is invalid.'); throw new DecryptException('MAC is invalid.');
} }
return $payload; return $payload;
} }
protected function validMac(array $payload)
{
return $payload['mac'] == $this->hash($payload['iv'], $payload['value']);
}
protected function hash($iv, $value) protected function hash($iv, $value)
{ {
return hash_hmac('sha256', $iv . $value, $this->key); return hash_hmac('sha256', $iv . $value, $this->key);
@ -6915,6 +7051,7 @@ class Logger implements LoggerInterface
const CRITICAL = 500; const CRITICAL = 500;
const ALERT = 550; const ALERT = 550;
const EMERGENCY = 600; const EMERGENCY = 600;
const API = 1;
protected static $levels = array(100 => 'DEBUG', 200 => 'INFO', 250 => 'NOTICE', 300 => 'WARNING', 400 => 'ERROR', 500 => 'CRITICAL', 550 => 'ALERT', 600 => 'EMERGENCY'); protected static $levels = array(100 => 'DEBUG', 200 => 'INFO', 250 => 'NOTICE', 300 => 'WARNING', 400 => 'ERROR', 500 => 'CRITICAL', 550 => 'ALERT', 600 => 'EMERGENCY');
protected static $timezone; protected static $timezone;
protected $name; protected $name;
@ -7141,6 +7278,7 @@ abstract class AbstractHandler implements HandlerInterface
throw new \InvalidArgumentException('Processors must be valid callables (callback or object with an __invoke method), ' . var_export($callback, true) . ' given'); throw new \InvalidArgumentException('Processors must be valid callables (callback or object with an __invoke method), ' . var_export($callback, true) . ' given');
} }
array_unshift($this->processors, $callback); array_unshift($this->processors, $callback);
return $this;
} }
public function popProcessor() public function popProcessor()
{ {
@ -7152,6 +7290,7 @@ abstract class AbstractHandler implements HandlerInterface
public function setFormatter(FormatterInterface $formatter) public function setFormatter(FormatterInterface $formatter)
{ {
$this->formatter = $formatter; $this->formatter = $formatter;
return $this;
} }
public function getFormatter() public function getFormatter()
{ {
@ -7163,6 +7302,7 @@ abstract class AbstractHandler implements HandlerInterface
public function setLevel($level) public function setLevel($level)
{ {
$this->level = $level; $this->level = $level;
return $this;
} }
public function getLevel() public function getLevel()
{ {
@ -7171,6 +7311,7 @@ abstract class AbstractHandler implements HandlerInterface
public function setBubble($bubble) public function setBubble($bubble)
{ {
$this->bubble = $bubble; $this->bubble = $bubble;
return $this;
} }
public function getBubble() public function getBubble()
{ {
@ -7303,18 +7444,16 @@ class RotatingFileHandler extends StreamHandler
if (!empty($fileInfo['extension'])) { if (!empty($fileInfo['extension'])) {
$glob .= '.' . $fileInfo['extension']; $glob .= '.' . $fileInfo['extension'];
} }
$iterator = new \GlobIterator($glob); $logFiles = glob($glob);
$count = $iterator->count(); if ($this->maxFiles >= count($logFiles)) {
if ($this->maxFiles >= $count) {
return; return;
} }
$array = iterator_to_array($iterator); usort($logFiles, function ($a, $b) {
usort($array, function ($a, $b) { return strcmp($b, $a);
return strcmp($b->getFilename(), $a->getFilename());
}); });
foreach (array_slice($array, $this->maxFiles) as $file) { foreach (array_slice($logFiles, $this->maxFiles) as $file) {
if ($file->isWritable()) { if (is_writable($file)) {
unlink($file->getRealPath()); unlink($file);
} }
} }
} }
@ -7819,7 +7958,8 @@ class Route extends BaseRoute
protected function getAllBeforeFilters(Request $request) protected function getAllBeforeFilters(Request $request)
{ {
$before = $this->getBeforeFilters(); $before = $this->getBeforeFilters();
return array_merge($before, $this->router->findPatternFilters($request)); $patterns = $this->router->findPatternFilters($request->getMethod(), $request->getPathInfo());
return array_merge($before, $patterns);
} }
protected function callAfterFilters(Request $request, $response) protected function callAfterFilters(Request $request, $response)
{ {
@ -7935,7 +8075,7 @@ class Route extends BaseRoute
} }
public function setBeforeFilters($value) public function setBeforeFilters($value)
{ {
$filters = is_string($value) ? explode('|', $value) : (array) $value; $filters = $this->parseFilterValue($value);
$this->setOption('_before', array_merge($this->getBeforeFilters(), $filters)); $this->setOption('_before', array_merge($this->getBeforeFilters(), $filters));
} }
public function getAfterFilters() public function getAfterFilters()
@ -7944,9 +8084,17 @@ class Route extends BaseRoute
} }
public function setAfterFilters($value) public function setAfterFilters($value)
{ {
$filters = is_string($value) ? explode('|', $value) : (array) $value; $filters = $this->parseFilterValue($value);
$this->setOption('_after', array_merge($this->getAfterFilters(), $filters)); $this->setOption('_after', array_merge($this->getAfterFilters(), $filters));
} }
protected function parseFilterValue($value)
{
$results = array();
foreach ((array) $value as $filters) {
$results = array_merge($results, explode('|', $filters));
}
return $results;
}
public function setParameters($parameters) public function setParameters($parameters)
{ {
$this->parameters = $parameters; $this->parameters = $parameters;
@ -8109,7 +8257,8 @@ class Environment
{ {
$path = $this->finder->find($view); $path = $this->finder->find($view);
$data = array_merge($mergeData, $this->parseData($data)); $data = array_merge($mergeData, $this->parseData($data));
return new View($this, $this->getEngineFromPath($path), $view, $path, $data); $this->callCreator($view = new View($this, $this->getEngineFromPath($path), $view, $path, $data));
return $view;
} }
protected function parseData($data) protected function parseData($data)
{ {
@ -8170,47 +8319,64 @@ class Environment
$this->share($innerKey, $innerValue); $this->share($innerKey, $innerValue);
} }
} }
public function creator($views, $callback)
{
$creators = array();
foreach ((array) $views as $view) {
$creators[] = $this->addViewEvent($view, $callback, 'creating: ');
}
return $creators;
}
public function composer($views, $callback) public function composer($views, $callback)
{ {
$composers = array(); $composers = array();
foreach ((array) $views as $view) { foreach ((array) $views as $view) {
$composers[] = $this->addComposer($view, $callback); $composers[] = $this->addViewEvent($view, $callback);
} }
return $composers; return $composers;
} }
protected function addComposer($view, $callback) protected function addViewEvent($view, $callback, $prefix = 'composing: ')
{ {
if ($callback instanceof Closure) { if ($callback instanceof Closure) {
$this->events->listen('composing: ' . $view, $callback); $this->events->listen($prefix . $view, $callback);
return $callback; return $callback;
} elseif (is_string($callback)) { } elseif (is_string($callback)) {
return $this->addClassComposer($view, $callback); return $this->addClassEvent($view, $callback, $prefix);
} }
} }
protected function addClassComposer($view, $class) protected function addClassEvent($view, $class, $prefix)
{ {
$name = 'composing: ' . $view; $name = $prefix . $view;
$callback = $this->buildClassComposerCallback($class); $callback = $this->buildClassEventCallback($class, $prefix);
$this->events->listen($name, $callback); $this->events->listen($name, $callback);
return $callback; return $callback;
} }
protected function buildClassComposerCallback($class) protected function buildClassEventCallback($class, $prefix)
{ {
$container = $this->container; $container = $this->container;
list($class, $method) = $this->parseClassComposer($class); list($class, $method) = $this->parseClassEvent($class, $prefix);
return function () use($class, $method, $container) { return function () use($class, $method, $container) {
$callable = array($container->make($class), $method); $callable = array($container->make($class), $method);
return call_user_func_array($callable, func_get_args()); return call_user_func_array($callable, func_get_args());
}; };
} }
protected function parseClassComposer($class) protected function parseClassEvent($class, $prefix)
{ {
return str_contains($class, '@') ? explode('@', $class) : array($class, 'compose'); if (str_contains($class, '@')) {
return explode('@', $class);
} else {
$method = str_contains($prefix, 'composing') ? 'compose' : 'create';
return array($class, $method);
}
} }
public function callComposer(View $view) public function callComposer(View $view)
{ {
$this->events->fire('composing: ' . $view->getName(), array($view)); $this->events->fire('composing: ' . $view->getName(), array($view));
} }
public function callCreator(View $view)
{
$this->events->fire('creating: ' . $view->getName(), array($view));
}
public function startSection($section, $content = '') public function startSection($section, $content = '')
{ {
if ($content === '') { if ($content === '') {
@ -8246,9 +8412,9 @@ class Environment
$this->sections[$section] = $content; $this->sections[$section] = $content;
} }
} }
public function yieldContent($section) public function yieldContent($section, $default = '')
{ {
return isset($this->sections[$section]) ? $this->sections[$section] : ''; return isset($this->sections[$section]) ? $this->sections[$section] : $default;
} }
public function flushSections() public function flushSections()
{ {
@ -8300,6 +8466,10 @@ class Environment
{ {
return $this->events; return $this->events;
} }
public function setDispatcher(Dispatcher $events)
{
$this->events = $events;
}
public function getContainer() public function getContainer()
{ {
return $this->container; return $this->container;
@ -8414,6 +8584,11 @@ class MessageBag implements ArrayableInterface, Countable, JsonableInterface, Me
public function setFormat($format = ':message') public function setFormat($format = ':message')
{ {
$this->format = $format; $this->format = $format;
return $this;
}
public function isEmpty()
{
return !$this->any();
} }
public function any() public function any()
{ {
@ -9119,8 +9294,16 @@ class Response
$obStatus = ob_get_status(1); $obStatus = ob_get_status(1);
while (($level = ob_get_level()) > 0 && $level !== $previous) { while (($level = ob_get_level()) > 0 && $level !== $previous) {
$previous = $level; $previous = $level;
if ($obStatus[$level - 1] && isset($obStatus[$level - 1]['del']) && $obStatus[$level - 1]['del']) { if ($obStatus[$level - 1]) {
ob_end_flush(); if (version_compare(PHP_VERSION, '5.4', '>=')) {
if (isset($obStatus[$level - 1]['flags']) && $obStatus[$level - 1]['flags'] & PHP_OUTPUT_HANDLER_REMOVABLE) {
ob_end_flush();
}
} else {
if (isset($obStatus[$level - 1]['del']) && $obStatus[$level - 1]['del']) {
ob_end_flush();
}
}
} }
} }
flush(); flush();
@ -9837,15 +10020,18 @@ class Run
} }
} }
$output = ob_get_clean(); $output = ob_get_clean();
if ($this->allowQuit()) { if ($this->writeToOutput()) {
echo $output; if ($handlerResponse == Handler::QUIT && $this->allowQuit()) {
die; while (ob_get_level() > 0) {
} else { ob_end_clean();
if ($this->writeToOutput()) { }
echo $output;
} }
return $output; echo $output;
} }
if ($handlerResponse == Handler::QUIT && $this->allowQuit()) {
die;
}
return $output;
} }
public function handleError($level, $message, $file = null, $line = null) public function handleError($level, $message, $file = null, $line = null)
{ {

View file

@ -2,7 +2,8 @@
"require": { "require": {
"laravel/framework": "4.0.*", "laravel/framework": "4.0.*",
"kriswallsmith/assetic": "1.2.*@dev", "kriswallsmith/assetic": "1.2.*@dev",
"codescale/ffmpeg-php": "2.7.0" "codescale/ffmpeg-php": "2.7.0",
"simplepie/simplepie": "1.3.1"
}, },
"autoload": { "autoload": {
"classmap": [ "classmap": [

View file

@ -33,7 +33,7 @@
$bundle->setTargetPath($filePath); $bundle->setTargetPath($filePath);
} }
$bundle = new AssetCache($bundle, new FilesystemCache("$cacheDirectory/scripts")); // $bundle = new AssetCache($bundle, new FilesystemCache("$cacheDirectory/scripts"));
} else if ($_GET['type'] == 'less') { } else if ($_GET['type'] == 'less') {
header('Content-Type: text/css'); header('Content-Type: text/css');

View file

@ -8,8 +8,10 @@ angular.module('ponyfm').controller "dashboard", [
($scope, dashboard) -> ($scope, dashboard) ->
$scope.recentTracks = null $scope.recentTracks = null
$scope.popularTracks = null $scope.popularTracks = null
$scope.news = null
dashboard.refresh().done (res) -> dashboard.refresh().done (res) ->
$scope.recentTracks = res.recent_tracks $scope.recentTracks = res.recent_tracks
$scope.popularTracks = res.popular_tracks $scope.popularTracks = res.popular_tracks
$scope.news = res.news
] ]

View file

@ -342,7 +342,7 @@ html {
line-height: normal; line-height: normal;
padding: 0px; padding: 0px;
margin: 5px 0px; padding: 5px 0px;
padding-right: 10px; padding-right: 10px;
position: relative; position: relative;
@ -384,6 +384,10 @@ html {
margin-top: 5px; margin-top: 5px;
} }
.artist {
.ellipsis();
}
.artist, .stats, .genre, .stats-expanded { .artist, .stats, .genre, .stats-expanded {
color: #777; color: #777;
font-size: 80%; font-size: 80%;

View file

@ -1,13 +1,49 @@
@import-once "base/bootstrap/bootstrap"; @import-once "base/bootstrap/bootstrap";
.dashboard {
h1 {
background: @pfm-purple;
color: #fff;
font-size: 10pt;
padding: 5px;
margin: 0px;
margin-bottom: 5px;
}
}
@media (max-width: 1300px) and (min-width: 720px) {
html .dashboard {
.recent-tracks {
width: 50%;
.tracks-listing > li:nth-child(1n+15) {
display: none;
}
}
.popular-tracks {
width: 50%;
float: right;
}
.news {
width: 50%;
clear: left;
}
}
}
.recent-tracks { .recent-tracks {
h1 { h1 {
a { a {
color: #fff;
display: block; display: block;
float: right; float: right;
font-size: 10pt; font-size: 10pt;
background: darken(@pfm-purple, 20%);
margin-top: 8px; margin: -5px;
margin-left: 0px;
padding: 5px;
} }
} }
} }
@ -16,8 +52,19 @@
section { section {
.box-sizing(border-box); .box-sizing(border-box);
float: left;
width: 50%;
padding: 5px; padding: 5px;
float: left;
}
.recent-tracks {
width: 37.5%;
}
.popular-tracks {
width: 37.5%;
}
.news {
width: 25%;
} }
} }

View file

@ -1,20 +1,28 @@
<div class="dashboard stretch-to-bottom"> <div class="dashboard stretch-to-bottom">
<section class="recent-tracks"> <section class="recent-tracks">
<div> <h1>
<h1> <a href="/tracks"><i class="icon-music"></i> see more</a>
<a href="/tracks"><i class="icon-music"></i> see more</a> The Newest Tunes
The Newest Tunes </h1>
</h1> <pfm-tracks-list tracks="recentTracks" class="two-columns"></pfm-tracks-list>
<pfm-tracks-list tracks="recentTracks" class="two-columns"></pfm-tracks-list>
</div>
</section> </section>
<section class="popular-tracks"> <section class="popular-tracks">
<div> <h1>
<h1> What's Popular Today
What's Popular Today </h1>
</h1> <pfm-tracks-list tracks="popularTracks" class="two-columns"></pfm-tracks-list>
<pfm-tracks-list tracks="popularTracks" class="two-columns"></pfm-tracks-list> </section>
</div>
<section class="news">
<h1>Pony.fm News</h1>
<ul>
<li ng-repeat="post in news">
<a href="{{post.url}}">
{{post.title}}
<em>{{post.date}}</em>
</a>
</li>
</ul>
</section> </section>
</div> </div>

View file

@ -33,6 +33,7 @@
<excludeFolder url="file://$MODULE_DIR$/vendor/react/event-loop" /> <excludeFolder url="file://$MODULE_DIR$/vendor/react/event-loop" />
<excludeFolder url="file://$MODULE_DIR$/vendor/react/socket" /> <excludeFolder url="file://$MODULE_DIR$/vendor/react/socket" />
<excludeFolder url="file://$MODULE_DIR$/vendor/react/stream" /> <excludeFolder url="file://$MODULE_DIR$/vendor/react/stream" />
<excludeFolder url="file://$MODULE_DIR$/vendor/simplepie/simplepie" />
<excludeFolder url="file://$MODULE_DIR$/vendor/swiftmailer/swiftmailer" /> <excludeFolder url="file://$MODULE_DIR$/vendor/swiftmailer/swiftmailer" />
<excludeFolder url="file://$MODULE_DIR$/vendor/symfony/browser-kit" /> <excludeFolder url="file://$MODULE_DIR$/vendor/symfony/browser-kit" />
<excludeFolder url="file://$MODULE_DIR$/vendor/symfony/console" /> <excludeFolder url="file://$MODULE_DIR$/vendor/symfony/console" />
@ -66,14 +67,7 @@
<root url="file://$MODULE_DIR$/vendor/psr/log" /> <root url="file://$MODULE_DIR$/vendor/psr/log" />
<root url="file://$MODULE_DIR$/vendor/filp/whoops" /> <root url="file://$MODULE_DIR$/vendor/filp/whoops" />
<root url="file://$MODULE_DIR$/vendor/nikic/php-parser" /> <root url="file://$MODULE_DIR$/vendor/nikic/php-parser" />
<root url="file://$MODULE_DIR$/vendor/react/socket" />
<root url="file://$MODULE_DIR$/vendor/react/stream" />
<root url="file://$MODULE_DIR$/vendor/react/event-loop" />
<root url="file://$MODULE_DIR$/vendor/cboden/ratchet" />
<root url="file://$MODULE_DIR$/vendor/guzzle/http" />
<root url="file://$MODULE_DIR$/vendor/guzzle/common" />
<root url="file://$MODULE_DIR$/vendor/guzzle/parser" /> <root url="file://$MODULE_DIR$/vendor/guzzle/parser" />
<root url="file://$MODULE_DIR$/vendor/guzzle/stream" />
<root url="file://$MODULE_DIR$/vendor/nesbot/carbon" /> <root url="file://$MODULE_DIR$/vendor/nesbot/carbon" />
<root url="file://$MODULE_DIR$/vendor/predis/predis" /> <root url="file://$MODULE_DIR$/vendor/predis/predis" />
<root url="file://$MODULE_DIR$/vendor/laravel/framework" /> <root url="file://$MODULE_DIR$/vendor/laravel/framework" />
@ -100,9 +94,9 @@
<root url="file://$MODULE_DIR$/vendor/doctrine/annotations" /> <root url="file://$MODULE_DIR$/vendor/doctrine/annotations" />
<root url="file://$MODULE_DIR$/vendor/doctrine/collections" /> <root url="file://$MODULE_DIR$/vendor/doctrine/collections" />
<root url="file://$MODULE_DIR$/vendor/codescale/ffmpeg-php" /> <root url="file://$MODULE_DIR$/vendor/codescale/ffmpeg-php" />
<root url="file://$MODULE_DIR$/vendor/evenement/evenement" />
<root url="file://$MODULE_DIR$/vendor/ircmaxell/password-compat" /> <root url="file://$MODULE_DIR$/vendor/ircmaxell/password-compat" />
<root url="file://$MODULE_DIR$/vendor/patchwork/utf8" /> <root url="file://$MODULE_DIR$/vendor/patchwork/utf8" />
<root url="file://$MODULE_DIR$/vendor/simplepie/simplepie" />
<root url="file://$MODULE_DIR$/vendor/swiftmailer/swiftmailer" /> <root url="file://$MODULE_DIR$/vendor/swiftmailer/swiftmailer" />
<root url="file://$MODULE_DIR$/vendor/kriswallsmith/assetic" /> <root url="file://$MODULE_DIR$/vendor/kriswallsmith/assetic" />
<root url="file://$MODULE_DIR$/vendor/classpreloader/classpreloader" /> <root url="file://$MODULE_DIR$/vendor/classpreloader/classpreloader" />
@ -112,14 +106,7 @@
<root url="file://$MODULE_DIR$/vendor/psr/log" /> <root url="file://$MODULE_DIR$/vendor/psr/log" />
<root url="file://$MODULE_DIR$/vendor/filp/whoops" /> <root url="file://$MODULE_DIR$/vendor/filp/whoops" />
<root url="file://$MODULE_DIR$/vendor/nikic/php-parser" /> <root url="file://$MODULE_DIR$/vendor/nikic/php-parser" />
<root url="file://$MODULE_DIR$/vendor/react/socket" />
<root url="file://$MODULE_DIR$/vendor/react/stream" />
<root url="file://$MODULE_DIR$/vendor/react/event-loop" />
<root url="file://$MODULE_DIR$/vendor/cboden/ratchet" />
<root url="file://$MODULE_DIR$/vendor/guzzle/http" />
<root url="file://$MODULE_DIR$/vendor/guzzle/common" />
<root url="file://$MODULE_DIR$/vendor/guzzle/parser" /> <root url="file://$MODULE_DIR$/vendor/guzzle/parser" />
<root url="file://$MODULE_DIR$/vendor/guzzle/stream" />
<root url="file://$MODULE_DIR$/vendor/nesbot/carbon" /> <root url="file://$MODULE_DIR$/vendor/nesbot/carbon" />
<root url="file://$MODULE_DIR$/vendor/predis/predis" /> <root url="file://$MODULE_DIR$/vendor/predis/predis" />
<root url="file://$MODULE_DIR$/vendor/laravel/framework" /> <root url="file://$MODULE_DIR$/vendor/laravel/framework" />
@ -146,9 +133,9 @@
<root url="file://$MODULE_DIR$/vendor/doctrine/annotations" /> <root url="file://$MODULE_DIR$/vendor/doctrine/annotations" />
<root url="file://$MODULE_DIR$/vendor/doctrine/collections" /> <root url="file://$MODULE_DIR$/vendor/doctrine/collections" />
<root url="file://$MODULE_DIR$/vendor/codescale/ffmpeg-php" /> <root url="file://$MODULE_DIR$/vendor/codescale/ffmpeg-php" />
<root url="file://$MODULE_DIR$/vendor/evenement/evenement" />
<root url="file://$MODULE_DIR$/vendor/ircmaxell/password-compat" /> <root url="file://$MODULE_DIR$/vendor/ircmaxell/password-compat" />
<root url="file://$MODULE_DIR$/vendor/patchwork/utf8" /> <root url="file://$MODULE_DIR$/vendor/patchwork/utf8" />
<root url="file://$MODULE_DIR$/vendor/simplepie/simplepie" />
<root url="file://$MODULE_DIR$/vendor/swiftmailer/swiftmailer" /> <root url="file://$MODULE_DIR$/vendor/swiftmailer/swiftmailer" />
<root url="file://$MODULE_DIR$/vendor/kriswallsmith/assetic" /> <root url="file://$MODULE_DIR$/vendor/kriswallsmith/assetic" />
<root url="file://$MODULE_DIR$/vendor/classpreloader/classpreloader" /> <root url="file://$MODULE_DIR$/vendor/classpreloader/classpreloader" />