summary refs log tree commit diff stats
path: root/web
diff options
context:
space:
mode:
authorAraq <rumpf_a@web.de>2014-08-05 21:53:26 +0200
committerAraq <rumpf_a@web.de>2014-08-05 21:53:26 +0200
commitcf61072cc94649dc08c849ef2c8b076c28de5b35 (patch)
treef548903ca973f5336b353c008a0b0be8e62f4142 /web
parentca8135f34b30b5c9da62f6d55f6bc5726206535b (diff)
parent915d3291ab57d59e41877c98dba97d6388c56a35 (diff)
downloadNim-cf61072cc94649dc08c849ef2c8b076c28de5b35.tar.gz
Merge branch 'devel' of https://github.com/Araq/Nimrod into devel
Conflicts:
	compiler/ccgexprs.nim
Diffstat (limited to 'web')
-rw-r--r--web/babelpkglist.nim11
1 files changed, 4 insertions, 7 deletions
diff --git a/web/babelpkglist.nim b/web/babelpkglist.nim
index 8745c9f99..5da7d60a9 100644
--- a/web/babelpkglist.nim
+++ b/web/babelpkglist.nim
@@ -21,7 +21,7 @@ proc processContent(content: string) =
   var jsonArr = jsonDoc.elems
 
   jsonArr.sort do (x, y: PJsonNode) -> int:
-    system.cmp(x["name"].str, y["name"].str)
+    strutils.cmpIgnoreCase(x["name"].str, y["name"].str)
 
   var
     officialList = ""
@@ -38,8 +38,7 @@ proc processContent(content: string) =
       else: pkg["url"].str
     let
       desc = pkg["description"].str
-      # Review array index access when #1291 is solved.
-      dot = if desc.high > 0 and desc[<desc.high] in endings: "" else: "."
+      dot = if desc.high > 0 and desc[desc.high] in endings: "" else: "."
       listItem = li(a(href=pkgWeb, pkg["name"].str), " ", desc & dot)
     if pkg["url"].str.startsWith("git://github.com/nimrod-code") or
        "official" in pkg["tags"].elems:
@@ -51,19 +50,17 @@ proc processContent(content: string) =
 
   var officialPkgListDiv = document.getElementById("officialPkgList")
 
-  officialPkgListDiv.innerHTML.add(
+  officialPkgListDiv.innerHTML =
     p("There are currently " & $officialCount &
       " official packages in the Babel package repository.") &
     ul(officialList)
-  )
 
   var unofficialPkgListDiv = document.getElementById("unofficialPkgList")
 
-  unofficialPkgListDiv.innerHTML.add(
+  unofficialPkgListDiv.innerHTML =
     p("There are currently " & $unofficialCount &
       " unofficial packages in the Babel package repository.") &
     ul(unofficialList)
-  )
 
 proc gotPackageList(apiReply: TData) {.exportc.} =
   let decoded = decodeContent($apiReply.content)