1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Is _postSaveAfterTransaction executed after the responseView?

Discussion in 'XenForo Development Discussions' started by Marcus, Oct 24, 2013.

  1. Marcus

    Marcus Well-Known Member

    I wonder if _postSaveAfterTransaction is executed after the responseView the user gets? So I could add some more time consuming code there which not slows down user experience?
  2. ManOnDaMoon

    ManOnDaMoon Well-Known Member

    I believe it is executed once a DataWriter has committed its changes and before returning from save(). If the DW save() is called within an action, so no, it is executed before returning the responseView.
    Marcus likes this.
  3. Chris D

    Chris D XenForo Developer Staff Member

    You'll want to look at Deferred actions for things that can be executed in the background.
    Marcus likes this.
  4. Marcus

    Marcus Well-Known Member

    Thanks! Isn't it useful to defer all functions like _postSaveAfterTransaction?
  5. Marcus

    Marcus Well-Known Member

Share This Page