mirror of
https://github.com/go-gitea/gitea.git
synced 2026-10-14 01:35:55 +09:00
Fix unwatch button not working in Firefox
This commit is contained in:
1 parent
536f65b8ad
commit
0b4fcf1224
1 file changed
+4
-2
+4
-2
@@ -406,8 +406,10 @@ function initRepository() {
|
||||
// watching script
|
||||
(function () {
|
||||
var $watch = $('#repo-watching'),
|
||||
watchLink = $watch.data("watch"),
|
||||
unwatchLink = $watch.data("unwatch");
|
||||
watchLink = $watch.attr("data-watch"),
|
||||
// Use $.attr() to work around jQuery not finding $.data("unwatch") in Firefox,
|
||||
// which has a method "unwatch" on `Object` that gets returned instead.
|
||||
unwatchLink = $watch.attr("data-unwatch");
|
||||
$watch.on('click', '.to-watch', function () {
|
||||
if ($watch.hasClass("watching")) {
|
||||
return false;
|
||||
|
||||
Reference in new issue
Block a user