remove unneeded variable & proper element creation

Signed-off-by: Morris Jobke <hey@morrisjobke.de>
This commit is contained in:
Morris Jobke 2016-10-10 13:55:27 +02:00
parent 2dcd97bf14
commit 5158328190
No known key found for this signature in database
GPG Key ID: 9CE5ED29E7FCD38A
1 changed files with 2 additions and 5 deletions

View File

@ -14,11 +14,8 @@
* this gets only loaded if an update is available and then shows a temporary notification
*/
$(document).ready(function(){
var head = $('html > head'),
version = oc_updateState.updateVersion,
docLink = oc_updateState.updateLink,
text = t('core', '{version} is available. Get more information on how to update.', {version: version}),
element = $('<a href="'+escapeHTML(docLink)+'" target="_blank">'+escapeHTML(text)+'</a>');
var text = t('core', '{version} is available. Get more information on how to update.', {version: oc_updateState.updateVersion}),
element = $('<a>').attr('href', oc_updateState.updateLink).attr('target','_blank').text(text);
OC.Notification.showTemporary(
element,