[csw-devel] SF.net SVN: gar:[15687] csw/mgar/gar/v2/lib/web/pkgdb_web.py

wahwah at users.sourceforge.net wahwah at users.sourceforge.net
Tue Sep 20 18:11:21 CEST 2011


Revision: 15687
          http://gar.svn.sourceforge.net/gar/?rev=15687&view=rev
Author:   wahwah
Date:     2011-09-20 16:11:21 +0000 (Tue, 20 Sep 2011)
Log Message:
-----------
pkgdb-web: Allow REST queries from other domains

Modified Paths:
--------------
    csw/mgar/gar/v2/lib/web/pkgdb_web.py

Modified: csw/mgar/gar/v2/lib/web/pkgdb_web.py
===================================================================
--- csw/mgar/gar/v2/lib/web/pkgdb_web.py	2011-09-20 14:20:02 UTC (rev 15686)
+++ csw/mgar/gar/v2/lib/web/pkgdb_web.py	2011-09-20 16:11:21 UTC (rev 15687)
@@ -276,6 +276,7 @@
       pkg = models.Srv4FileStats.selectBy(md5_sum=md5_sum).getOne()
       mimetype, data_structure = pkg.GetRestRepr()
       web.header('Content-type', mimetype)
+      web.header('Access-Control-Allow-Origin', '*')
       return json.dumps(data_structure)
     except sqlobject.main.SQLObjectNotFound, e:
       raise web.notfound()

This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.



More information about the devel mailing list