hunk.code_window:     let annRelBoolExp = cBoolExp nesAnn
           innerBoolExp = S.BEBin S.AndOp backCompExp annRelBoolExp
       S.mkExists relTN innerBoolExp
   inBoolExpBuilder :: S.SQLExp -> [S.SQLExp] -> S.BoolExp
   inBoolExpBuilder qualColExp rhsExps =
     foldr (S.BEBin S.OrOp) (S.BELit False) eqExps
     where
       eqExps = map (equalsBoolExpBuilder qualColExp) rhsExps
   -- txtValParser
   --   :: (MonadError QErr m)
   --   => ValueParser m (AnnValOpExpG S.SQLExp)
   -- txtValParser =
   --   undefined
  
hunk.labels: keep keep keep keep replace replace replace replace replace replace keep keep keep keep keep
hunk.file_path: server/src-lib/Hasura/RQL/GBoolExp.hs
hunk.type: replace
file: // Initialize Firebase
  var config = {
    apiKey: "xxxxxxxxxxxxxxxxxxxxxxxxxx",
    authDomain: "<your-app>.firebaseapp.com",
    databaseURL: "https://<your-app>.firebaseio.com",
    projectId: "<your-app>",
    storageBucket: "<your-app>.appspot.com",
    messagingSenderId: "xxxxxxxxxxxx"
  };
  firebase.initializeApp(config);
  
  document.getElementById('login-form').onsubmit = function(event) {
    event.preventDefault();
    let email = document.getElementById('email').value;
    let pass = document.getElementById('password').value;
    login(email, pass);
  };
  
  
  document.getElementById('get-token').onclick = function(event) {
    event.preventDefault();
    firebase.auth().currentUser.getIdToken(true).
      then(token => document.getElementById('id-token').innerHTML = token);
  };
  
  function login(email, password) {
    firebase.auth().signInWithEmailAndPassword(email, password)
      .then(function(user) {
        console.log('login success');
      })
      .catch(function(error) {
        // Handle Errors here.
        var errorCode = error.code;
        var errorMessage = error.message;
        console.log(error);
      });
  
    let callback = null;
    let metadataRef = null;
    firebase.auth().onAuthStateChanged(user => {
      // Remove previous listener.
      if (callback) {
        metadataRef.off('value', callback);
      }
      // On user login add new listener.
      if (user) {
        // Check if refresh is required.
        metadataRef = firebase.database().ref('metadata/' + user.uid + '/refreshTime');
        callback = (snapshot) => {
          // Force refresh to pick up the latest custom claims changes.
          // Note this is always triggered on first call. Further optimization could be
          // added to avoid the initial trigger when the token is issued and already contains
          // the latest claims.
          user.getIdToken(true);
        };
        // Subscribe new listener to changes on that node.
        metadataRef.on('value', callback);
      }
    });
  }
  