Skip to content

Commit

Permalink
ProcessWire v3.0.33 RC1 primarily prepares all of ProcessWire's core …
Browse files Browse the repository at this point in the history
…files to reflect a non-development version. This also contains improvements to documentation in several files.
  • Loading branch information
ryancramerdesign committed Sep 2, 2016
1 parent 8f92484 commit e4c8339
Show file tree
Hide file tree
Showing 234 changed files with 1,121 additions and 904 deletions.
438 changes: 0 additions & 438 deletions README-PW.md

This file was deleted.

511 changes: 439 additions & 72 deletions README.md

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion index.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
* do so after you have installed the site, as the installer is not informed
* of any changes made in this file.
*
* ProcessWire 3.x (development), Copyright 2015 by Ryan Cramer
* ProcessWire 3.x, Copyright 2016 by Ryan Cramer
* https://processwire.com
*
* @version 3.0
Expand Down
2 changes: 1 addition & 1 deletion install.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* If that file exists, the installer will not run. So if you need to re-run this installer for any
* reason, then you'll want to delete that file. This was implemented just in case someone doesn't delete the installer.
*
* ProcessWire 3.x (development), Copyright 2016 by Ryan Cramer
* ProcessWire 3.x, Copyright 2016 by Ryan Cramer
* https://processwire.com
*
*/
Expand Down
2 changes: 1 addition & 1 deletion site-beginner/config.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* This file is licensed under the MIT license
* https://processwire.com/about/license/mit/
*
* ProcessWire 3.x (development), Copyright 2015 by Ryan Cramer
* ProcessWire 3.x, Copyright 2016 by Ryan Cramer
* https://processwire.com
*
*/
Expand Down
2 changes: 1 addition & 1 deletion site-blank/config.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* This file is licensed under the MIT license
* https://processwire.com/about/license/mit/
*
* ProcessWire 3.x (development), Copyright 2015 by Ryan Cramer
* ProcessWire 3.x, Copyright 2016 by Ryan Cramer
* https://processwire.com
*
*/
Expand Down
2 changes: 1 addition & 1 deletion site-classic/config.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* This file is licensed under the MIT license
* https://processwire.com/about/license/mit/
*
* ProcessWire 3.x (development), Copyright 2015 by Ryan Cramer
* ProcessWire 3.x, Copyright 2016 by Ryan Cramer
* https://processwire.com
*
*/
Expand Down
2 changes: 1 addition & 1 deletion site-default/config.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* This file is licensed under the MIT license
* https://processwire.com/about/license/mit/
*
* ProcessWire 3.x (development), Copyright 2015 by Ryan Cramer
* ProcessWire 3.x, Copyright 2016 by Ryan Cramer
* https://processwire.com
*
*/
Expand Down
2 changes: 1 addition & 1 deletion site-default/modules/Helloworld.module
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
* This file is licensed under the MIT license
* https://processwire.com/about/license/mit/
*
* ProcessWire 3.x (development), Copyright 2015 by Ryan Cramer
* ProcessWire 3.x, Copyright 2016 by Ryan Cramer
* https://processwire.com
*
*/
Expand Down
2 changes: 1 addition & 1 deletion site-languages/config.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* This file is licensed under the MIT license
* https://processwire.com/about/license/mit/
*
* ProcessWire 3.x (development), Copyright 2015 by Ryan Cramer
* ProcessWire 3.x, Copyright 2016 by Ryan Cramer
* https://processwire.com
*
*/
Expand Down
2 changes: 1 addition & 1 deletion wire/config.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
* You may also make up your own configuration options by assigning them
* in /site/config.php
*
* ProcessWire 3.x (development), Copyright 2015 by Ryan Cramer
* ProcessWire 3.x, Copyright 2016 by Ryan Cramer
* https://processwire.com
*
*
Expand Down
7 changes: 5 additions & 2 deletions wire/core/AdminTheme.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,13 @@
* This file is licensed under the MIT license.
* https://processwire.com/about/license/mit/
*
* ProcessWire 3.x (development), Copyright 2015 by Ryan Cramer
* ProcessWire 3.x, Copyright 2016 by Ryan Cramer
* https://processwire.com
*
* @property int|string $version Current admin theme version
*
* @method void install()
* @method void uninstall()
*
*/

Expand Down Expand Up @@ -248,7 +251,7 @@ public function preRenderURL($url = '') {
if(!empty($url)) $this->preRenderURLs[] = $url;
return $this->preRenderURLs;
}

public function ___uninstall() {

/*
Expand Down
2 changes: 1 addition & 1 deletion wire/core/Breadcrumbs.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
* This file is licensed under the MIT license.
* https://processwire.com/about/license/mit/
*
* ProcessWire 3.x (development), Copyright 2015 by Ryan Cramer
* ProcessWire 3.x, Copyright 2016 by Ryan Cramer
* https://processwire.com
*
*
Expand Down
4 changes: 3 additions & 1 deletion wire/core/CacheFile.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
* This file is licensed under the MIT license
* https://processwire.com/about/license/mit/
*
* ProcessWire 3.x (development), Copyright 2015 by Ryan Cramer
* ProcessWire 3.x, Copyright 2016 by Ryan Cramer
* https://processwire.com
*
*/
Expand Down Expand Up @@ -218,6 +218,8 @@ public function remove() {

/**
* Removes just the given file, as opposed to remove() which removes the entire cache for primaryID
*
* @param string $filename
*
*/
protected function removeFilename($filename) {
Expand Down
2 changes: 1 addition & 1 deletion wire/core/Config.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
* This file is licensed under the MIT license
* https://processwire.com/about/license/mit/
*
* ProcessWire 3.x (development), Copyright 2015 by Ryan Cramer
* ProcessWire 3.x, Copyright 2016 by Ryan Cramer
* https://processwire.com
*
* #pw-summary Holds ProcessWire configuration settings as defined in /wire/config.php and /site/config.php.
Expand Down
2 changes: 1 addition & 1 deletion wire/core/ConfigurableModule.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
* This file is licensed under the MIT license
* https://processwire.com/about/license/mit/
*
* ProcessWire 3.x (development), Copyright 2015 by Ryan Cramer
* ProcessWire 3.x, Copyright 2016 by Ryan Cramer
* https://processwire.com
*
*
Expand Down
2 changes: 1 addition & 1 deletion wire/core/Database.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
* This file is licensed under the MIT license
* https://processwire.com/about/license/mit/
*
* ProcessWire 3.x (development), Copyright 2015 by Ryan Cramer
* ProcessWire 3.x, Copyright 2016 by Ryan Cramer
* https://processwire.com
*
*
Expand Down
2 changes: 1 addition & 1 deletion wire/core/DatabaseQuery.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
* of what other methods/objects have done to it. It also means being able
* to build a complex query without worrying about correct syntax placement.
*
* ProcessWire 3.x (development), Copyright 2015 by Ryan Cramer
* ProcessWire 3.x, Copyright 2016 by Ryan Cramer
* https://processwire.com
*
* This file is licensed under the MIT license
Expand Down
2 changes: 1 addition & 1 deletion wire/core/DatabaseQuerySelect.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
* This file is licensed under the MIT license
* https://processwire.com/about/license/mit/
*
* ProcessWire 3.x (development), Copyright 2015 by Ryan Cramer
* ProcessWire 3.x, Copyright 2016 by Ryan Cramer
* https://processwire.com
*
* @property array $select
Expand Down
2 changes: 1 addition & 1 deletion wire/core/DatabaseQuerySelectFulltext.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
* This file is licensed under the MIT license
* https://processwire.com/about/license/mit/
*
* ProcessWire 3.x (development), Copyright 2015 by Ryan Cramer
* ProcessWire 3.x, Copyright 2016 by Ryan Cramer
* https://processwire.com
*
*
Expand Down
11 changes: 10 additions & 1 deletion wire/core/DatabaseStopwords.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
*
* MySQL stopwords, primarily for use with filtering fulltext queries
*
* ProcessWire 3.x (development), Copyright 2015 by Ryan Cramer
* ProcessWire 3.x, Copyright 2016 by Ryan Cramer
* https://processwire.com
*
*
Expand Down Expand Up @@ -54,6 +54,8 @@ class DatabaseStopwords {

/**
* Get all stopwords
*
* @return array
*
*/
static public function getAll() {
Expand All @@ -62,6 +64,9 @@ static public function getAll() {

/**
* Is the provided word a stopword?
*
* @param string $word
* @return bool
*
*/
static public function has($word) {
Expand All @@ -70,6 +75,8 @@ static public function has($word) {

/**
* Add a stopword to the list
*
* @param string $word
*
*/
static public function add($word) {
Expand All @@ -78,6 +85,8 @@ static public function add($word) {

/**
* Remove a word from the stopwords
*
* @param string $word
*
*/
static public function remove($word) {
Expand Down
31 changes: 27 additions & 4 deletions wire/core/Debug.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,17 +10,35 @@
* This file is licensed under the MIT license
* https://processwire.com/about/license/mit/
*
* ProcessWire 3.x (development), Copyright 2015 by Ryan Cramer
* ProcessWire 3.x, Copyright 2016 by Ryan Cramer
* https://processwire.com
*
*/

class Debug {


/**
* Current timers
*
* @var array
*
*/
static protected $timers = array();


/**
* Timers that have been saved
*
* @var array
*
*/
static protected $savedTimers = array();


/**
* Notes for saved timers
*
* @var array
*
*/
static protected $savedTimerNotes = array();

/**
Expand Down Expand Up @@ -108,6 +126,9 @@ static public function getSavedTimers() {

/**
* Reset a timer so that it starts timing again from right now
*
* @param string $key
* @return string|int
*
*/
static public function resetTimer($key) {
Expand All @@ -117,6 +138,8 @@ static public function resetTimer($key) {

/**
* Remove a timer completely
*
* @param string $key
*
*/
static public function removeTimer($key) {
Expand Down
2 changes: 1 addition & 1 deletion wire/core/Exceptions.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
* This file is licensed under the MIT license
* https://processwire.com/about/license/mit/
*
* ProcessWire 3.x (development), Copyright 2015 by Ryan Cramer
* ProcessWire 3.x, Copyright 2016 by Ryan Cramer
* https://processwire.com
*
*/
Expand Down
12 changes: 8 additions & 4 deletions wire/core/Field.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
* #pw-body Field objects are managed by the `$fields` API variable.
* #pw-use-constants
*
* ProcessWire 3.x (development), Copyright 2015 by Ryan Cramer
* ProcessWire 3.x, Copyright 2016 by Ryan Cramer
* https://processwire.com
*
* @property int $id Numeric ID of field in the database #pw-group-properties
Expand Down Expand Up @@ -524,14 +524,17 @@ public function setImportData(array $data) {
public function setName($name) {
$name = $this->wire('sanitizer')->fieldName($name);

if(Fields::isNativeName($name))
if($this->wire('fields')->isNative($name)) {
throw new WireException("Field may not be named '$name' because it is a reserved word");
}

if($this->wire('fields') && ($f = $this->wire('fields')->get($name)) && $f->id != $this->id)
if($this->wire('fields') && ($f = $this->wire('fields')->get($name)) && $f->id != $this->id) {
throw new WireException("Field may not be named '$name' because it is already used by another field");
}

if(strpos($name, '__') !== false)
if(strpos($name, '__') !== false) {
throw new WireException("Field name '$name' may not have double underscores because this usage is reserved by the core");
}

if($this->settings['name'] != $name) {
if($this->settings['name'] && ($this->settings['flags'] & Field::flagSystem)) {
Expand All @@ -542,6 +545,7 @@ public function setName($name) {
}

$this->settings['name'] = $name;

return $this;
}

Expand Down
2 changes: 1 addition & 1 deletion wire/core/FieldSelectorInfo.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
* This file is licensed under the MIT license
* https://processwire.com/about/license/mit/
*
* ProcessWire 3.x (development), Copyright 2015 by Ryan Cramer
* ProcessWire 3.x, Copyright 2016 by Ryan Cramer
* https://processwire.com
*
*/
Expand Down
3 changes: 1 addition & 2 deletions wire/core/Fieldgroup.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
* are separated in the API in case want want to have fieldgroups used by
* multiple templates in the future (like ProcessWire 1.x).
*
* ProcessWire 3.x (development), Copyright 2015 by Ryan Cramer
* ProcessWire 3.x, Copyright 2016 by Ryan Cramer
* https://processwire.com
*
* @property int $id Fieldgroup database ID #pw-group-retrieval
Expand Down Expand Up @@ -176,7 +176,6 @@ public function remove($field) {
*
* #pw-internal
*
* @internal
* @param Field $field
* @return bool
*
Expand Down
Loading

0 comments on commit e4c8339

Please sign in to comment.