Fixed some chaining bugs
Documentation