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

Fixed Moving Featured Resources

Discussion in 'Resource Manager Resolved Bugs' started by Syndol, Nov 14, 2013.

  1. Syndol

    Syndol Guest

    When a featured resource is moved to a new category it no longer is featured even though it is still in the feature table.
    Changing the condition in the Category datawriter resourceUpdate() function from:
    Code:
    if ($resource->isUpdate() && $resource->isChanged('resource_state'))
    {
        $this->updateFeaturedCount();
    }
    to:
    Code:
    if ($resource->isUpdate() && ($resource->isChanged('resource_state') || $resource->isChanged('resource_category_id')))
    {
        $this->updateFeaturedCount();
    }
    seems to fix this.
     
    Adam Howard likes this.
  2. Mike

    Mike XenForo Developer Staff Member

    Slightly different fix (I basically just put the code up a bit), but fixed now. Thanks. :)
     

Share This Page