Console Error on login & home page in V5.8.1
Posted: 2020-01-14 06:48
Hate to be picky but I just upgraded an app to V5.8.1 and noticed that /common.js is causing a console error when loading the login and home page (or any other non /admin/ page without a table name in the URL).
Error: "AppGini.currentTableName: Could not retrieve table name from page URL"
The error is caused by this snippet at line 1857 of common.js as of course there is no table name in the URL of those pages:
To replicate - load either of these pages and check the console for errors: https://bigprof.com/demo/index.php?signIn=1 or https://bigprof.com/demo/index.php
AppGini.currentTableName = function() appears to have been introduced since v5.80 for calculated fields so this is a new error? It doesn't seem to create any issues that I can see but any error in the console is far from perfect and not a particularly good look.
As I'm not entirely sure what AppGini.currentTableName = function() is doing so I haven't had a go at fixing the error. Just reporting for what it's worth.
Error: "AppGini.currentTableName: Could not retrieve table name from page URL"
The error is caused by this snippet at line 1857 of common.js as of course there is no table name in the URL of those pages:
Code: Select all
AppGini.currentTableName = function() {
// retrieve current table name from page URL
var tables = location.href.match(/\/([a-zA-Z0-9_]+)_view\.php/);
if(undefined == tables || undefined == tables.length || undefined == tables[1]) {
console.error('AppGini.currentTableName: Could not retrieve table name from page URL');
return false;
}
AppGini.currentTableName = function() appears to have been introduced since v5.80 for calculated fields so this is a new error? It doesn't seem to create any issues that I can see but any error in the console is far from perfect and not a particularly good look.
As I'm not entirely sure what AppGini.currentTableName = function() is doing so I haven't had a go at fixing the error. Just reporting for what it's worth.