Merge pull request #49 from alDuncanson/feature/firebase-security

Added security to Firebase in application.
This commit is contained in:
Alex Duncanson 2018-11-14 17:08:03 -05:00 committed by GitHub
commit 1739c89f4c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 8 additions and 0 deletions

View File

@ -1,6 +1,7 @@
import firebase from 'firebase/app'; import firebase from 'firebase/app';
import 'firebase/database'; import 'firebase/database';
import 'firebase/storage'; import 'firebase/storage';
import 'firebase/auth';
const config = { const config = {
apiKey: "AIzaSyAYf9AbeYwLY892NRiQfn0AMtG9xIFAJbo", apiKey: "AIzaSyAYf9AbeYwLY892NRiQfn0AMtG9xIFAJbo",
@ -13,4 +14,11 @@ const config = {
firebase.initializeApp(config); firebase.initializeApp(config);
firebase.auth().signInAnonymously().catch(error => {
var errorCode = error.code;
var errorMessage = error.message;
console.log(errorCode + " - " + errorMessage);
});
export default firebase; export default firebase;