-
Notifications
You must be signed in to change notification settings - Fork 416
Conversation
Why would it change? The code is still the same. All I basically did was update things for Laravel 4.2. In this case that just meant changing Environment to Factory, cause it got renamed in 4.2. |
Just noticed that all my commit messages got truncated. No idea why... |
Hmm, I'm not sure about completely removing support for 4.1 (forcing people to use an old version of the package) unless it's absolutely necessary, nor about pinning it to L4.2, completely preventing it being installed on L4.3+. I've not had time to try L4.2 myself yet, but I thought the only required change was removing the type hint.
It's an automated message, don't worry about it! |
Sorry just noticed it says |
Well, 4.2 makes breaking changes, so I don't see how you can support both 4.1 and 4.2 without different branches (currently you only have master, right?), unless you're adding checks for the Laravel version. Personally, I'd create a 4.1 branch and then leave the master branch to go forward with 4.2. |
As far as the code goes, it looks like removing the type hint is all that's required to support both. In the unit tests it looks like the only thing that changed is the class name, so an I don't plan to support older versions of Laravel forever, but I'd rather avoid maintaining multiple branches in the meantime. Thanks |
Yup, if that's the way you want to do it, then that's fine. Do you want me to submit another PR or are you gonna do that? |
If you could that would be great (you should be able to update this one) - I probably won't have a chance to get into it until the weekend, but if it's working OK I can at least merge it into master from GitHub. Cheers. |
Ok, will do it tomorrow. Already too late where I am... |
Brilliant work, just ran into this one myself and was about to cook up my own PR. Looking forward to this making it's way into the package. |
Ok, have re-added support for Laravel 4.1. Unfortunately, we can't type hint the Factory/Environment class in the Manager constructor anymore, so I just added a check for those and it throws an InvalidArgumentException now if it's neither. Also adjusted the test classes. |
Thanks. 👍 I've merged it into master for testing. I'll try to make a new release with it soon, before L4.2 is released. |
Ok, cool! Still think that a separate branch would be better,,, |
I'm not convinced. This way I only have one branch to maintain - no messing around with merging and releasing multiple versions. The changes are so minor I really can't see any point in having a separate branch. |
Released as v2.2.1. Thanks again for your help. |
I changed
Illuminate\View\Environment
toIlluminate\View\Factory
, changed the variable name from$environment
to$factory
and bumped the Mockery dependency to ~0.9.0, cause PHPUnit 4.0 was throwing errors for 0.8. Because Laravel 4.2 is PHP 5.4 and up only I also removed the PHP 5.3 tests from .travis.yml.