lists don't have a copy() method. grrrr
authorDavid E. Eisenstat <deisenst@cs.princeton.edu>
Mon, 30 Oct 2006 16:21:42 +0000 (16:21 +0000)
committerDavid E. Eisenstat <deisenst@cs.princeton.edu>
Mon, 30 Oct 2006 16:21:42 +0000 (16:21 +0000)
api.py

diff --git a/api.py b/api.py
index 0dd7115..567d10b 100644 (file)
--- a/api.py
+++ b/api.py
@@ -77,7 +77,7 @@ def GetRSpec(rec):
 @export_to_api(1)
 def GetLoans(rec):
     """GetLoans(sliver_name): return the list of loans made by the specified sliver"""
-    return rec.get('_loans', []).copy()
+    return rec.get('_loans', [])[:]
 
 def validate_loans(obj):
     """Check that <obj> is a valid loan specification."""