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 * as path from 'path'; | |
import * as cdk from '@aws-cdk/core'; | |
import * as ddb from '@aws-cdk/aws-dynamodb'; | |
import * as apiGatewayV2 from '@aws-cdk/aws-apigatewayv2'; | |
import { LambdaProxyIntegration } from '@aws-cdk/aws-apigatewayv2-integrations'; | |
import { NodejsFunction, NodejsFunctionProps } from '@aws-cdk/aws-lambda-nodejs'; | |
import { HttpIntegration, HttpIntegrationType } from '@aws-cdk/aws-apigatewayv2'; | |
import { dirname } from 'path'; | |
const project_root_dir = path.join(dirname(__filename), '../') |
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 .ignore support plugin (hsz.mobi) | |
### Python template | |
# Byte-compiled / optimized / DLL files | |
__pycache__/ | |
*.py[cod] | |
*$py.class | |
# C extensions | |
*.so |
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
# REF: http://www.quora.com/How-do-I-create-and-update-embedded-documents-with-MongoEngine | |
class Comment(EmbeddedDocument): | |
content = StringField() | |
name = StringField(max_length=120) | |
class Post(Document): | |
title = StringField(max_length=120, required=True) | |
author = StringField(required=True) |
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
<?php | |
/* | |
* Add FCM Class | |
*/ | |
class Google_Service_Fcm extends Google_Service | |
{ | |
/** Set URL for Google Cloud Platform services. */ | |
const CLOUD_PLATFORM = "https://www.googleapis.com/auth/cloud-platform"; | |
const FCM = "https://www.googleapis.com/auth/firebase.messaging"; |
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 AVFoundation | |
extension AVPlayer { | |
var isPlaying: Bool { | |
if (self.rate != 0 && self.error == nil) { | |
return true | |
} else { | |
return false |