skip to Main Content

I have kinda messed up my project and need some help asap. So I have made a dashboard for my company completely on Laravel. It was working great until I used composer require to update a package. But instead of updating that single package, it updated all and even removed some of them. Because of that, the site went down. And it also started showing multiple errors.

Is there a way to restore the composer file somehow or did I mess up big time? Any help is appreciated!!

I tried to use the composer.lock file to get back to the older version of the packages but I had the very old version of it because the latest version was not committed..even that didn’t work..at first, at least I was getting errors now it just shows ‘Http error 5000’.

2

Answers


  1. Did you try these commands yet?

    1. rm -rf vendor/

    2. composer update

    3. https://itecnote.com/tecnote/laravel-how-to-revert-back-composer-update/

    Login or Signup to reply.
  2. Here are some solutions you could try out.

    1. If you have versioned your project you could.

    Git to revert back to a previous commit where your project was working correctly. To do this, run "git log" to identify the commit you want to revert to, and then run "git checkout [commit hash]" to switch to that commit

    1. use your IDE history

    Using your IDE history you can target the specific files and reset your composer.json, composer.lock back to the previous working version

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search