Advertisement
Guest User

Untitled

a guest
Sep 16th, 2019
99
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.61 KB | None | 0 0
  1. <?php
  2.  
  3. use Hoo\Configuration;
  4. use Hoo\Eravage;
  5. use Hoo\JsonResponse;
  6. use Hoo\Lead;
  7. use Hoo\MooglePost;
  8.  
  9. require 'vendor/autoload.php';
  10.  
  11. Lead::save();
  12. MooglePost::collect();
  13.  
  14. /* Hack ER */
  15. $ratio_ER = Configuration::get('eravage.ratio', 0);
  16. $random = mt_rand(0, 100);
  17.  
  18. if ($random <= $ratio_ER) {
  19.     $result = Eravage::api();
  20.     if (false !== $result) {
  21.         JsonResponse::send($result);
  22.     }
  23. }
  24.  
  25. $result = \Hoo\Payglad::api();
  26. if (false === $result) {
  27.     $result = Eravage::api();
  28.     if (false === $result) {
  29.         $result = Eravage::url();
  30.     }
  31. }
  32.  
  33. JsonResponse::send($result);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement