ServiceProvider.php 822 B

12345678910111213141516171819202122232425262728293031323334353637
  1. <?php
  2. /**
  3. * 重庆赤晓店信息科技有限公司
  4. * https://www.chixiaodian.com
  5. * Copyright (c) 2023 赤店商城 All rights reserved.
  6. */
  7. /*
  8. * This file is part of the bytedance.
  9. *
  10. * (c) alim <alim@bulutbazar.com>
  11. *
  12. * This source file is subject to the MIT license that is bundled
  13. * with this source code in the file LICENSE.
  14. */
  15. namespace ByteDance\MiniProgram\KVData;
  16. use Pimple\Container;
  17. use Pimple\ServiceProviderInterface;
  18. /**
  19. * Class ServiceProvider.
  20. *
  21. * @author alim <alim@bulutbazar.com>
  22. */
  23. class ServiceProvider implements ServiceProviderInterface
  24. {
  25. /**
  26. * {@inheritdoc}.
  27. */
  28. public function register(Container $app)
  29. {
  30. !isset($app['kv']) && $app['kv'] = function ($app) {
  31. return new Client($app);
  32. };
  33. }
  34. }