This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<%= content_tag(:body, { | |
class: [ | |
current_user.signposting_level_class | |
] | |
} %> | |
<%# The rest of the page %> | |
<% end %> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
+ (void)swapMethod:(SEL)origM withMethod:(SEL)newM inClass:(Class)class { | |
Method origMethod = class_getInstanceMethod(class, origM); | |
Method newMethod = class_getInstanceMethod(class, newM); | |
if (class_addMethod(class, origM, method_getImplementation(newMethod), method_getTypeEncoding(newMethod))) { | |
class_replaceMethod(class, newM, method_getImplementation(origMethod), method_getTypeEncoding(origMethod)); | |
} else { | |
method_exchangeImplementations(origMethod, newMethod); | |
} | |
} |
OlderNewer