Skip to content

Commit 3c3908d

Browse files
Update subnets.html
Don't break old links, use comments only if provided.
1 parent 8299a07 commit 3c3908d

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

subnets.html

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -437,10 +437,15 @@
437437
{
438438
preloadSubnetImages();
439439
args = parseQueryString();
440-
if (args['network'] && args['mask'] && args['division'] && args['comments']) {
440+
if (args['network'] && args['mask'] && args['division']) {
441441
document.forms['calc'].elements['network'].value = args['network'];
442442
document.forms['calc'].elements['netbits'].value = args['mask'];
443-
curComments = JSON.parse(args['comments']);
443+
444+
if (args['comments']) {
445+
curComments = JSON.parse(args['comments']);
446+
} else {
447+
curComments = {};
448+
}
444449
updateNetwork();
445450
var division = asciiToBin(args['division']);
446451
rootSubnet = [0, 0, null];

0 commit comments

Comments
 (0)