removed todo's

This commit is contained in:
Andy Miller
2015-09-13 19:25:43 -06:00
parent 42987d96e3
commit 70e347cfce
8 changed files with 2 additions and 12 deletions

View File

@@ -385,7 +385,6 @@ class Validation
*/
public static function typeDatetime($value, array $params, array $field)
{
// TODO: add min, max and range.
if ($value instanceof \DateTime) {
return true;
} elseif (!is_string($value)) {

View File

@@ -111,7 +111,7 @@ class Installer
public static function nonSophisticatedInstall(\ZipArchive $zip, $install_path, $tmp)
{
$container = $zip->getNameIndex(0); // TODO: better way of determining if zip has container folder
$container = $zip->getNameIndex(0);
if (file_exists($install_path)) {
Folder::delete($install_path);
}

View File

@@ -701,7 +701,6 @@ class Page
public function file()
{
if ($this->name) {
// TODO: use CompiledMarkdownFile after fixing issues in it.
return MarkdownFile::instance($this->filePath());
}
return null;
@@ -740,12 +739,11 @@ class Page
$clone->_original = $this;
$clone->parent($parent);
$clone->id(time().md5($clone->filePath()));
// TODO: make sure that the path is in user context.
if ($parent->path()) {
$clone->path($parent->path() . '/' . $clone->folder());
}
// TODO: make sure we always have the route.
if ($parent->route()) {
$clone->route($parent->route() . '/'. $clone->slug());
} else {
@@ -1854,7 +1852,6 @@ class Page
}
$collection->setParams($params);
// TODO: MOVE THIS INTO SOMEWHERE ELSE?
/** @var Uri $uri */
$uri = self::getGrav()['uri'];
/** @var Config $config */
@@ -1879,7 +1876,6 @@ class Page
}
}
}
// TODO: END OF MOVE
if (isset($params['dateRange'])) {
$start = isset($params['dateRange']['start']) ? $params['dateRange']['start'] : 0;

View File

@@ -886,7 +886,6 @@ class Pages
foreach ($list as $key => $sort) {
$info = $pages[$key];
// TODO: order by manual needs a hash from the passed variables if we make this more general.
$this->sort[$path][$order_by][$key] = $info;
}
}

View File

@@ -62,7 +62,6 @@ class Taxonomy
foreach ((array) $config->get('site.taxonomies') as $taxonomy) {
if (isset($page_taxonomy[$taxonomy])) {
foreach ((array) $page_taxonomy[$taxonomy] as $item) {
// TODO: move to pages class?
$this->taxonomy_map[$taxonomy][(string) $item][$page->path()] = array('slug' => $page->slug());
}
}

View File

@@ -188,7 +188,6 @@ class Themes extends Iterator
/** @var UniformResourceLocator $locator */
$locator = $this->grav['locator'];
// TODO: move
$registered = stream_get_wrappers();
$schemes = $config->get(
"themes.{$name}.streams.schemes",

View File

@@ -173,7 +173,6 @@ class TwigExtension extends \Twig_Extension
*/
public function inflectorFilter($action, $data, $count = null)
{
// TODO: check this and fix the docblock if needed.
$action = $action.'ize';
$inflector = $this->grav['inflector'];

View File

@@ -31,7 +31,6 @@ class User extends Data
{
$locator = self::getGrav()['locator'];
// TODO: validate directory name
$blueprints = new Blueprints('blueprints://');
$blueprint = $blueprints->get('user/account');
$file_path = $locator->findResource('account://' . $username . YAML_EXT);