Bugzilla – Attachment 122113 Details for
Bug 27170
ILL availability should be able to display arbitrary links to related resources
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 27170: Fix bug with undefined 'links'
Bug-27170-Fix-bug-with-undefined-links.patch (text/plain), 1.55 KB, created by
Andrew Isherwood
on 2021-06-18 10:00:17 UTC
(
hide
)
Description:
Bug 27170: Fix bug with undefined 'links'
Filename:
MIME Type:
Creator:
Andrew Isherwood
Created:
2021-06-18 10:00:17 UTC
Size:
1.55 KB
patch
obsolete
>From 5f64690b8cc9e7b5591ea57305dd6e124fdbe38b Mon Sep 17 00:00:00 2001 >From: Andrew Isherwood <andrew.isherwood@ptfs-europe.com> >Date: Fri, 18 Jun 2021 10:59:01 +0100 >Subject: [PATCH] Bug 27170: Fix bug with undefined 'links' > >If a row object doesn't have a 'links' property, calling 'length' on it >will fail. This commit fixes this. >--- > koha-tmpl/intranet-tmpl/prog/js/ill-availability.js | 2 +- > koha-tmpl/opac-tmpl/bootstrap/js/ill-availability.js | 2 +- > 2 files changed, 2 insertions(+), 2 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/js/ill-availability.js b/koha-tmpl/intranet-tmpl/prog/js/ill-availability.js >index 8515200063..a7da26ba1c 100644 >--- a/koha-tmpl/intranet-tmpl/prog/js/ill-availability.js >+++ b/koha-tmpl/intranet-tmpl/prog/js/ill-availability.js >@@ -1,7 +1,7 @@ > $(document).ready(function() { > > var getLinks = function(row) { >- if (row.links.length === 0) { >+ if (row.links && row.links.length === 0) { > return false; > } > return row.links.map(function(link) { >diff --git a/koha-tmpl/opac-tmpl/bootstrap/js/ill-availability.js b/koha-tmpl/opac-tmpl/bootstrap/js/ill-availability.js >index 239a3bfecd..9e4a57d6f4 100644 >--- a/koha-tmpl/opac-tmpl/bootstrap/js/ill-availability.js >+++ b/koha-tmpl/opac-tmpl/bootstrap/js/ill-availability.js >@@ -1,7 +1,7 @@ > $(document).ready(function() { > > var getLinks = function(row) { >- if (row.links.length === 0) { >+ if (row.links && row.links.length === 0) { > return false; > } > return row.links.map(function(link) { >-- >2.20.1
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 27170
:
114256
|
122112
|
122113
|
122114
|
122115
|
122117
|
122167
|
122168
|
122169
|
122632
|
122633
|
122634
|
123339
|
123340
|
123341