This file contains hidden or 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
import Foundation | |
import AuthenticationServices | |
import SafariServices | |
import FacebookCore | |
// This helper is a workaroung for the issue in https://github.com/facebook/facebook-ios-sdk/issues/2387 | |
// Starting with new FBSDK 17.0.0, the login method is not working as expected when the user has not given IDFA consent | |
// The workaround is to use ASWebAuthenticationSession to open the SafariViewController to perform the login manually | |
public class FacebookSignInHelper: NSObject, ASWebAuthenticationPresentationContextProviding { |
This file contains hidden or 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
# This script transforms a GitHub release json into a Slack message. It takes the content from the body and applies several transformations to make it look better in Slack. | |
# Usage: | |
# python3 format_github_release_to_slack.py [-pre-text <pre-text>] [-channel <channel>] | |
# -pre-text <pre-text>: Optional - text to be added as a first message. It accepts Slack markdown format. | |
# -channel <channel>: Optional - name of channel, for example #general | |
# | |
# Example using a previous message as input: | |
# `cat github_release.json | python3 scripts/format_github_release_to_slack.py "New Android release 5.74.0-RC1 available"` | |
# |
This file contains hidden or 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
//: Playground - noun: a place where people can play | |
import UIKit | |
//////////// | |
// Nested protocols not compiling | |
//////////// | |
protocol A { | |
protocol B {} | |
} |
This file contains hidden or 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
// | |
// SSLPinningValidator.swift | |
// | |
// Created by Angel Garcia on 17/08/16. | |
// | |
import Foundation | |
import CommonCrypto | |
protocol SSLPinningValidator { |
This file contains hidden or 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
// Created by Angel Garcia on 06/05/16. | |
import Foundation | |
extension NSObject { | |
private struct AssociatedKeys { | |
static var safeObservers = "safeObservers" | |
} | |
This file contains hidden or 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
typedef enum { | |
AGCommandPriorityLow = -10, | |
AGCommandPriorityDefault = 0, | |
AGCommandPriorityHigh = 10 | |
} AGCommandPriority; | |
@interface AGCommand : NSObject | |
@property(nonatomic, weak) NSObject *firingObject; | |
@property(nonatomic, readonly) SEL action; |
This file contains hidden or 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
{ | |
"name": "PayPalMPL", | |
"version": "2.1.3", | |
"summary": "PayPal MPL Payment library for iOS.", | |
"homepage": "https://www.paypal.com", | |
"license": { | |
"type": "Copyright", | |
"text": " Copyright (c) 2014 PayPal\n" | |
}, | |
"authors": "PayPal", |
This file contains hidden or 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
#import <objc/runtime.h> | |
@protocol Custom_PXBoxModel <NSObject> | |
- (BOOL)hasCornerRadius; | |
- (CGSize)radiusTopLeft; | |
- (CGSize)radiusTopRight; | |
- (CGSize)radiusBottomRight; | |
- (CGSize)radiusBottomLeft; | |
@end |
This file contains hidden or 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
@interface AGCommand : NSObject | |
@property(nonatomic, weak) UIResponder *firingObject; | |
@property(nonatomic, readonly) SEL action; | |
+ (instancetype)command; | |
@end |
This file contains hidden or 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
@interface AGCommand : NSObject | |
@property(nonatomic, weak) UIResponder *firingObject; | |
@property(nonatomic, readonly) SEL action; | |
+ (instancetype)command; | |
@end |
NewerOlder