diff options
author | Christian A. Weber | 2018-06-19 18:53:09 +0200 |
---|---|---|
committer | Christian A. Weber | 2018-06-19 18:53:09 +0200 |
commit | 4cd6a23b8c2a5f20f51d2a53b65bd7586e367a3c (patch) | |
tree | 8b6c0373eb4be682d299eea7ce944043495e0227 | |
parent | 82ff67d50a245c09f9c7c49b2c50f17b7dc06679 (diff) | |
download | itools-4cd6a23b8c2a5f20f51d2a53b65bd7586e367a3c.tar.gz itools-4cd6a23b8c2a5f20f51d2a53b65bd7586e367a3c.tar.bz2 itools-4cd6a23b8c2a5f20f51d2a53b65bd7586e367a3c.zip |
remove bogus function that nobody uses, fix comment of transmogrify()
-rw-r--r-- | it.class | 8 | ||||
-rw-r--r-- | it_text.class | 2 | ||||
-rwxr-xr-x | tests/it.t | 4 |
3 files changed, 1 insertions, 13 deletions
@@ -1055,14 +1055,6 @@ static function mail($p) } /** - * Add an extra md5 based directory name on bottom of path. foo/bar -> foo/07/bar - */ -static function add_dir($path) -{ - return dirname($path) . "/" . substr(md5(basename($path)), 0, 2) . "/" . basename($path); -} - -/** * Reads a file and returns it as string or in one of several formats. Two params: filename and flags * @param $filename name of file to read or - for stdin * @param $p['keyval'] each line of the file is one tab-separated key/value pair, return assoc array diff --git a/it_text.class b/it_text.class index 4481434..a8782ce 100644 --- a/it_text.class +++ b/it_text.class @@ -228,7 +228,7 @@ function set($label, $text = null, $language = null) /** - * Replaces variables of the form {obj.var} with value from $values, e.g. {user.name}, or result of a func, e.g. {LU:foo.html} + * Replaces variables of the form {obj.var} with value from $values, e.g. {user.name}, or result of a func, e.g. {LU(//www/terms)} * NOTE: Invalid object names or non-existing variables are simply deleted. */ function transmogrify($text, $values = null, $label = null, $allowedfuncs = null) @@ -454,10 +454,6 @@ is(it::map('2*$v', ['foo' => 1, 'bar' => 2], ['keys' => 'foo']), ['foo' => 2, 'b is(it::filter('$v > 2', [1, 5 => 2, 2 => 3]), [2 => 3]); is(it::filter('$k > 2', [1, 5 => 2, 2 => 3]), [5 => 2]); -is(it::add_dir("foo/bar"), "foo/37/bar"); -is(it::add_dir("baz/bar"), "baz/37/bar"); -is(it::add_dir("bar"), "./37/bar"); - is(it::split("b", "aba"), ["a", "a"]); is(it::split("b", "aBa"), ["a", "a"]); is(it::split("b", "abba"), ["a", "", "a"]); |