Error: Injector mapping override for type

ndangduy's Avatar


29 Aug, 2013 08:49 PM

I have a ReportView mapped as singleton in AppConfig.

Then in MainView,
public var injector:IInjector;
public var pageReport:ReportView;

injector.unmap( ReportView );
pageReport = injector.getOrCreateNewInstance(ReportView);

How come i always get error when i minimize the window:
Warning: Injector already has a mapping for|.
 If you have overridden this mapping intentionally you can use "injector.unmap()" prior to your replacement mapping in order to avoid seeing this message.
Error: Injector mapping override for type

  1. Support Staff 1 Posted by Ondina D.F. on 30 Aug, 2013 07:42 AM

    Ondina D.F.'s Avatar


    It looks like you have more than one mapping for your ReportView.
    I suppose that you are mapping the view to a mediator as well. Maybe you have 2 mappings for your ReportView, like these:;


    So, one mapping overrides the other, and that's why you're getting the error.
    To avoid this, you could use the ViewProcessorMapExtension instead of the mediatorMap: new MediatorCreator(ReportMediator));

    Let me know if that solves your problem.

    If that's not your use case, then you should provide more info. Show us your code where you perform the mappings. Or, you can attach your project or a simple example reproducing the issue as a zip file, and I'll take a look at it.


  2. Ondina D.F. closed this discussion on 23 Sep, 2013 02:36 PM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts


? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac