-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathTranslation.php
More file actions
37 lines (31 loc) · 1.5 KB
/
Translation.php
File metadata and controls
37 lines (31 loc) · 1.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
<?php
/*************************************************************************************/
/* This file is part of the Thelia package. */
/* */
/* Copyright (c) OpenStudio */
/* email : dev@thelia.net */
/* web : http://www.thelia.net */
/* */
/* For the full copyright and license information, please view the LICENSE.txt */
/* file that was distributed with this source code. */
/*************************************************************************************/
namespace Translation;
use Propel\Runtime\Connection\ConnectionInterface;
use Symfony\Component\Filesystem\Filesystem;
use Thelia\Module\BaseModule;
class Translation extends BaseModule
{
/** @var string */
const DOMAIN_NAME = 'translation';
const TRANSLATIONS_DIR = THELIA_LOCAL_DIR . 'translations' . DS;
public function postActivation(ConnectionInterface $con = null)
{
if (null === self::getConfigValue('extension')){
self::setConfigValue('extension' , 'po');
}
}
public static function deleteTmp()
{
(new Filesystem())->remove(self::TRANSLATIONS_DIR . 'tmp');
}
}