Fixed empty selector behavior for better compatibility with Floodgap indexes
This commit is contained in:
+2
-2
@@ -28,8 +28,8 @@ Hi01379 = (function(psGopherRequest) {
|
|||||||
sel = rest.length > 1 ? rest[1] : '' // selector
|
sel = rest.length > 1 ? rest[1] : '' // selector
|
||||||
host = rest.length > 2 ? rest[2] : '' // hostname
|
host = rest.length > 2 ? rest[2] : '' // hostname
|
||||||
port = rest.length > 3 ? (0|rest[3]) : '' // port
|
port = rest.length > 3 ? (0|rest[3]) : '' // port
|
||||||
// check for the empty fields
|
// selector defaults to the description only if there are no other fields
|
||||||
if(!sel) sel = desc // selector defaults to the description
|
if(!sel && rest.length < 2) sel = desc
|
||||||
if(!host) host = chost // host defaults to the current host
|
if(!host) host = chost // host defaults to the current host
|
||||||
if(!port) port = cport // port defaults to the current port
|
if(!port) port = cport // port defaults to the current port
|
||||||
if(type == 'i') { // information message - wrap them in pretag
|
if(type == 'i') { // information message - wrap them in pretag
|
||||||
|
|||||||
+1
-1
@@ -1,5 +1,5 @@
|
|||||||
{
|
{
|
||||||
"version": "0.0.2",
|
"version": "0.0.3",
|
||||||
"name": "Kopher",
|
"name": "Kopher",
|
||||||
"description": "A Gopher client for KaiOS",
|
"description": "A Gopher client for KaiOS",
|
||||||
"launch_path": "/index.html",
|
"launch_path": "/index.html",
|
||||||
|
|||||||
Reference in New Issue
Block a user