mirror of
https://github.com/Hopiu/angular.js.git
synced 2026-03-16 23:30:23 +00:00
fix(docs): correctly generate sitemap
This commit is contained in:
parent
6d9313a68d
commit
f0a090ddf2
2 changed files with 2 additions and 2 deletions
|
|
@ -15,7 +15,7 @@ describe('sitemap', function() {
|
|||
var map = new SiteMap([new Doc({section: 'foo', id: 'a.b.c<>\'"&'})]);
|
||||
expect(map.render()).toContain([
|
||||
' <url>',
|
||||
'<loc>http://docs.angularjs.org/#!/foo/a.b.c<>'"&</loc>',
|
||||
'<loc>http://docs.angularjs.org/foo/a.b.c<>'"&</loc>',
|
||||
'<changefreq>weekly</changefreq>',
|
||||
'</url>'].join(''));
|
||||
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ function SiteMap(docs){
|
|||
map.push('<?xml version="1.0" encoding="UTF-8"?>');
|
||||
map.push('<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">');
|
||||
docs.forEach(function(doc){
|
||||
map.push(' <url><loc>http://docs.angularjs.org/#!/' +
|
||||
map.push(' <url><loc>http://docs.angularjs.org/' +
|
||||
encode(doc.section) + '/' +
|
||||
encode(doc.id) +
|
||||
'</loc><changefreq>weekly</changefreq></url>');
|
||||
|
|
|
|||
Loading…
Reference in a new issue