Skip to content

Instantly share code, notes, and snippets.

@marinaglancy
marinaglancy / repository_github.diff
Created August 1, 2012 02:55
repository_github fix to test download error on moodle.org
diff --git a/lib.php b/lib.php
index ca85b5f..8e1f0ed 100644
--- a/lib.php
+++ b/lib.php
@@ -257,14 +257,12 @@ class repository_github extends repository {
$fp = fopen($path, 'w');
$c = new curl();
- $c->setopt(array('CURLOPT_FOLLOWLOCATION' => true, 'CURLOPT_MAXREDIRS' => 3));
- $result = $c->download(array(array('url' => $url, 'file'=> $fp)));