diff --git a/.scrutinizer.yml b/.scrutinizer.yml index c5d5b38..5cf6a42 100644 --- a/.scrutinizer.yml +++ b/.scrutinizer.yml @@ -14,6 +14,7 @@ checks: fix_php_opening_tag: true fix_linefeed: true fix_line_ending: true + # Known typo fix_identation_4spaces: true fix_doc_comments: true tools: diff --git a/CHANGELOG.md b/CHANGELOG.md index 847cca0..d447406 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -117,7 +117,7 @@ All Notable changes to `League\Container` will be documented in this file ### Added - Re-added the `share` proxy method that was mistakenly removed in previous major release. -- Added ability to set Conatiner to "share" by default using `defaultToShared` method. +- Added ability to set Container to "share" by default using `defaultToShared` method. - Added ability for `ReflectionContainer` to cache resolutions and pull from cache for following calls. ## 3.0.1 diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 0c45c52..d62f88d 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -2,7 +2,7 @@ Contributions are **welcome** and will be fully **credited**. -We accept contributions via Pull Requests on [Github](https://github.com/thephpleague/container). +We accept contributions via Pull Requests on [GitHub](https://github.com/thephpleague/container). ## Pull Requests diff --git a/docs/3.x/dependency-injection.md b/docs/3.x/dependency-injection.md index b5400a6..88545b6 100644 --- a/docs/3.x/dependency-injection.md +++ b/docs/3.x/dependency-injection.md @@ -161,7 +161,7 @@ var_dump($controller->model->pdo instanceof PDO); // true ## Factories -Container can accept any `callable` that will be used as a factory to resolve your classes. This is the most performant way to resolve your objects as no inspection is needed of the definition, however, this does reduce the amount of flexibilty you can take advantage of. +Container can accept any `callable` that will be used as a factory to resolve your classes. This is the most performant way to resolve your objects as no inspection is needed of the definition, however, this does reduce the amount of flexibility you can take advantage of. Using the same example as above, we can define it in Container as follows. diff --git a/docs/3.x/index.md b/docs/3.x/index.md index 0658e07..aa75b17 100644 --- a/docs/3.x/index.md +++ b/docs/3.x/index.md @@ -88,7 +88,7 @@ Dependency injection at it's core is as simple as that, and Container allows you ## Further Reading -I recommend reading the links below for further information about what problems dependncy injection solve. +I recommend reading the links below for further information about what problems dependency injection solve. - [Dependency Injection Wikipedia Entry](https://en.wikipedia.org/wiki/Dependency_injection). - [Inversion of Control Wikipedia Entry](https://en.wikipedia.org/wiki/Inversion_of_control). @@ -147,7 +147,7 @@ Or, use any other [PSR-4](http://www.php-fig.org/psr/psr-4/) compatible autoload Container allows you to register services, with or without their dependencies for later retrieval. It is a registry of sorts that when used correctly can allow you to implement the dependency injection design pattern. -Using the example in our [introduction](#introduction), we can start to take a look at how Container works. Now that `Acme\Foo` accepts `Acme\Bar` as a contructor argument, we can use Container to configure that. +Using the example in our [introduction](#introduction), we can start to take a look at how Container works. Now that `Acme\Foo` accepts `Acme\Bar` as a constructor argument, we can use Container to configure that. ~~~ php model->pdo instanceof PDO); // true ## Factories -Container can accept any `callable` that will be used as a factory to resolve your classes. This is the most performant way to resolve your objects as no inspection is needed of the definition, however, this does reduce the amount of flexibilty you can take advantage of. +Container can accept any `callable` that will be used as a factory to resolve your classes. This is the most performant way to resolve your objects as no inspection is needed of the definition, however, this does reduce the amount of flexibility you can take advantage of. Using the same example as above, we can define it in Container as follows. diff --git a/docs/4.x/index.md b/docs/4.x/index.md index 6df1408..233cf35 100644 --- a/docs/4.x/index.md +++ b/docs/4.x/index.md @@ -147,7 +147,7 @@ Or, use any other [PSR-4](http://www.php-fig.org/psr/psr-4/) compatible autoload Container allows you to register services, with or without their dependencies for later retrieval. It is a registry of sorts that when used correctly can allow you to implement the dependency injection design pattern. -Using the example in our [introduction](#introduction), we can start to take a look at how Container works. Now that `Acme\Foo` accepts `Acme\Bar` as a contructor argument, we can use Container to configure that. +Using the example in our [introduction](#introduction), we can start to take a look at how Container works. Now that `Acme\Foo` accepts `Acme\Bar` as a constructor argument, we can use Container to configure that. ~~~ php delegate($delegateContainer); // old $container->hasInDelegate($id); // new -$container->has($id); // checks main container and then all delagates +$container->has($id); // checks main container and then all delegates $delegateContainer->has($id); // check specifically in the delegate ~~~ diff --git a/docs/unstable/dependency-injection.md b/docs/unstable/dependency-injection.md index b65854f..d49dbbf 100644 --- a/docs/unstable/dependency-injection.md +++ b/docs/unstable/dependency-injection.md @@ -169,7 +169,7 @@ var_dump($controller->model->pdo instanceof PDO); // true ## Factories -Container can accept any `callable` that will be used as a factory to resolve your classes. This is the most performant way to resolve your objects as no inspection is needed of the definition, however, this does reduce the amount of flexibilty you can take advantage of. +Container can accept any `callable` that will be used as a factory to resolve your classes. This is the most performant way to resolve your objects as no inspection is needed of the definition, however, this does reduce the amount of flexibility you can take advantage of. Using the same example as above, we can define it in Container as follows. diff --git a/docs/unstable/index.md b/docs/unstable/index.md index 16bf281..233cf35 100644 --- a/docs/unstable/index.md +++ b/docs/unstable/index.md @@ -88,7 +88,7 @@ Dependency injection at it's core is as simple as that, and Container allows you ## Further Reading -I recommend reading the links below for further information about what problems dependncy injection solve. +I recommend reading the links below for further information about what problems dependency injection solve. - [Dependency Injection Wikipedia Entry](https://en.wikipedia.org/wiki/Dependency_injection). - [Inversion of Control Wikipedia Entry](https://en.wikipedia.org/wiki/Inversion_of_control). @@ -147,7 +147,7 @@ Or, use any other [PSR-4](http://www.php-fig.org/psr/psr-4/) compatible autoload Container allows you to register services, with or without their dependencies for later retrieval. It is a registry of sorts that when used correctly can allow you to implement the dependency injection design pattern. -Using the example in our [introduction](#introduction), we can start to take a look at how Container works. Now that `Acme\Foo` accepts `Acme\Bar` as a contructor argument, we can use Container to configure that. +Using the example in our [introduction](#introduction), we can start to take a look at how Container works. Now that `Acme\Foo` accepts `Acme\Bar` as a constructor argument, we can use Container to configure that. ~~~ php delegate($delegateContainer); // old $container->hasInDelegate($id); // new -$container->has($id); // checks main container and then all delagates +$container->has($id); // checks main container and then all delegates $delegateContainer->has($id); // check specifically in the delegate ~~~