Index: branches/wmf/1.17wmf1/skins/common/upload.js |
— | — | @@ -59,12 +59,12 @@ |
60 | 60 | row.appendChild( td ); |
61 | 61 | } |
62 | 62 | |
63 | | - if ( wgAjaxLicensePreview ) { |
| 63 | + var wpLicense = document.getElementById( 'wpLicense' ); |
| 64 | + if ( wgAjaxLicensePreview && wpLicense ) { |
64 | 65 | // License selector check |
65 | | - document.getElementById( 'wpLicense' ).onchange = licenseSelectorCheck; |
| 66 | + wpLicense.onchange = licenseSelectorCheck; |
66 | 67 | |
67 | 68 | // License selector table row |
68 | | - var wpLicense = document.getElementById( 'wpLicense' ); |
69 | 69 | var wpLicenseRow = wpLicense.parentNode.parentNode; |
70 | 70 | var wpLicenseTbody = wpLicenseRow.parentNode; |
71 | 71 | |