Skip to content

Commit

Permalink
Merge pull request #3406 from smotornyuk/3398-depend-on-group-in-reso…
Browse files Browse the repository at this point in the history
…urce-config

Groups inside resource.config can't be dependent on another groups
  • Loading branch information
amercader committed Feb 9, 2017
2 parents 7190281 + d5a636c commit 8b2c01a
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions ckan/lib/fanstatic_resources.py
Expand Up @@ -157,8 +157,12 @@ def create_resource(path, lib_name, count, inline=False):
if resource not in depends:
depends[resource] = []
for dep in depends[group]:
if dep not in depends[resource]:
depends[resource].append(dep)
if dep not in groups:
dep_resources = [dep]
else:
dep_resources = groups[dep]
diff = [res for res in dep_resources if res not in depends[resource]]
depends[resource].extend(diff)

# process each .js/.css file found
resource_list = []
Expand Down

0 comments on commit 8b2c01a

Please sign in to comment.