Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8775681
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T18:51:59+00:00 2026-06-13T18:51:59+00:00

I am using symfony2 and I use one service to notify my users based

  • 0

I am using symfony2 and I use one service to notify my users based in some action sof the system. Well, It worked pretty fine in my local environment, now in production I am having some issues.

The service is dlecared on services.txt as:

mybundle.notify:
    class: NC8Digital\CRMBundle\Services\Notify
    arguments: [ @doctrine.orm.entity_manager, @templating, @mailer ]

And the class is declared as

public function __construct(EntityManager $em, TimedTwigEngine $templating, \Swift_Mailer $mailer)

And I am receiving this error:

PHP Catchable fatal error:  Argument 2 passed to NC8Digital\\CRMBundle\\Services\\Notify::__construct() must be an instance of Symfony\\Bundle\\TwigBundle\\Debug\\TimedTwigEngine, instance of Symfony\\Bundle\\TwigBundle\\TwigEngine given, called in /mypath/app/cache/prod/appProdProjectContainer.php on line 367 and defined in /mypath/src/NC8Digital/CRMBundle/Services/Notify.php on line 43

First thing I tried was to change my constructor to solve the problem… got a 500 error on my browser, so I changed back.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-13T18:52:01+00:00Added an answer on June 13, 2026 at 6:52 pm

    Type-hint the second parameter with Symfony\Bundle\FrameworkBundle\Templating\EngineInterface.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I could use some help on this problem. I'm creating an application using Symfony2
Using symfony2 I am following this documentation to create and use a service for
I am using Symfony2 and Doctrine2 to build an application. One part of the
When using dev mode with a Symfony2.x application, one usually works in locale. Hence,
My question is related with the tests for some application in Symfony2. I use
Using symfony2 with twig templates, I normally use js embedded inside the *html.twig file
I'm using the symfony2 framework and I want to use the PHP's DateTime class
I am currently writing a REST API using Symfony2. I started using Symfony2 one
Maybe dumb question, I'm new to Symfony2 and I'm using it for one of
I have been using symfony2 and doctrine2. I am working with one entity manager.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.