Skip to content

Instantly share code, notes, and snippets.

@Sailias
Created July 6, 2012 18:27
Show Gist options
  • Save Sailias/3061840 to your computer and use it in GitHub Desktop.
Save Sailias/3061840 to your computer and use it in GitHub Desktop.
def get_all_assets(course)
assets = []
assets += course.assets
course.prerequisite_courses.each do |p_c|
assets += get_all_assets(p_c)
end
return assets
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment