Skip to content

Commit

Permalink
Namespace changes.
Browse files Browse the repository at this point in the history
  • Loading branch information
Mezzair committed Mar 6, 2020
1 parent e47d8fa commit e276742
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 10 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace Chumper\Zipper\Facades;
namespace Appoly\Zipper\Facades;

use Illuminate\Support\Facades\Facade;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace Chumper\Zipper\Repositories;
namespace Appoly\Zipper\Repositories;

/**
* RepositoryInterface that needs to be implemented by every Repository.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace Chumper\Zipper\Repositories;
namespace Appoly\Zipper\Repositories;

use Exception;
use ZipArchive;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
<?php

namespace Chumper\Zipper;
namespace Appoly\Zipper;

use Chumper\Zipper\Repositories\RepositoryInterface;
use Appoly\Zipper\Repositories\RepositoryInterface;
use Exception;
use Illuminate\Filesystem\Filesystem;

Expand Down Expand Up @@ -87,10 +87,10 @@ public function make($pathToFile, $type = 'zip')

$objectOrName = $type;
if (is_string($type)) {
$objectOrName = 'Chumper\Zipper\Repositories\\'.ucwords($type).'Repository';
$objectOrName = 'Appoly\Zipper\Repositories\\'.ucwords($type).'Repository';
}

if (! is_subclass_of($objectOrName, 'Chumper\Zipper\Repositories\RepositoryInterface')) {
if (! is_subclass_of($objectOrName, 'Appoly\Zipper\Repositories\RepositoryInterface')) {
throw new \InvalidArgumentException("Class for '{$objectOrName}' must implement RepositoryInterface interface");
}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace Chumper\Zipper;
namespace Appoly\Zipper;

use Illuminate\Foundation\AliasLoader;
use Illuminate\Support\ServiceProvider;
Expand All @@ -27,14 +27,14 @@ public function boot()
public function register()
{
$this->app->singleton('zipper', function ($app) {
$return = $app->make('Chumper\Zipper\Zipper');
$return = $app->make('Appoly\Zipper\Zipper');

return $return;
});

$this->app->booting(function () {
$loader = AliasLoader::getInstance();
$loader->alias('Zipper', 'Chumper\Zipper\Facades\Zipper');
$loader->alias('Zipper', 'Appoly\Zipper\Facades\Zipper');
});
}

Expand Down

0 comments on commit e276742

Please sign in to comment.