Remove unnecessary return statements
These statements were automatically added by CoffeeScript. I'm only removing the obvious cases; there might be more cases where the `return` statement isn't necessary.
This commit is contained in:
@@ -1,21 +1,18 @@
|
||||
// Generated by CoffeeScript 1.12.6
|
||||
(function() {
|
||||
"use strict";
|
||||
App.FixedBar = {
|
||||
initialize: function() {
|
||||
return $("[data-fixed-bar]").each(function() {
|
||||
$("[data-fixed-bar]").each(function() {
|
||||
var $this, fixedBarTopPosition;
|
||||
$this = $(this);
|
||||
fixedBarTopPosition = $this.offset().top;
|
||||
return $(window).on("scroll", function() {
|
||||
$(window).on("scroll", function() {
|
||||
if ($(window).scrollTop() > fixedBarTopPosition) {
|
||||
$this.addClass("is-fixed");
|
||||
return $("#check-ballot").css({
|
||||
"display": "inline-block"
|
||||
});
|
||||
$("#check-ballot").css({ "display": "inline-block" });
|
||||
} else {
|
||||
$this.removeClass("is-fixed");
|
||||
return $("#check-ballot").hide();
|
||||
$("#check-ballot").hide();
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user