| @@ -196,7 +196,7 @@ | ||
| 196 | 196 | /** | 
| 197 | 197 | * Determine if the user is marked as available for an event. | 
| 198 | 198 | * | 
| 199 | - * @return bool if user is available | |
| 199 | + * @return null|boolean if user is available | |
| 200 | 200 | */ | 
| 201 | 201 | public function isAvailableForEvent(Event $event) | 
| 202 | 202 |      { | 
| @@ -2,8 +2,6 @@ | ||
| 2 | 2 | |
| 3 | 3 | namespace TechWilk\Rota; | 
| 4 | 4 | |
| 5 | -use DateTime; | |
| 6 | - | |
| 7 | 5 | /* | 
| 8 | 6 | This file is part of Church Rota. | 
| 9 | 7 | |
| @@ -119,6 +119,9 @@ | ||
| 119 | 119 | return true; | 
| 120 | 120 | } | 
| 121 | 121 | |
| 122 | + /** | |
| 123 | + * @param EmailAddress $username | |
| 124 | + */ | |
| 122 | 125 | private function numberOfLoginAttemptsIsOk($username) | 
| 123 | 126 |      { | 
| 124 | 127 | $numberOfAllowedAttempts = 8; | 
| @@ -148,6 +148,12 @@ discard block | ||
| 148 | 148 | return $statement->fetchAll(PDO::FETCH_CLASS, $returnClass); | 
| 149 | 149 | } | 
| 150 | 150 | |
| 151 | + /** | |
| 152 | + * @param string $returnClass | |
| 153 | + * @param string $table | |
| 154 | + * @param string[] $columns | |
| 155 | + * @param string[] $where | |
| 156 | + */ | |
| 151 | 157 | public function selectSingle($returnClass, $table, $columns, $where = null) | 
| 152 | 158 |      { | 
| 153 | 159 | $statement = $this->selectStatement($table, $columns, $where); | 
| @@ -215,6 +221,8 @@ discard block | ||
| 215 | 221 | |
| 216 | 222 | /** | 
| 217 | 223 | * Use with caution: it is often better to archive items to prevent creating null references. | 
| 224 | + * @param string $table | |
| 225 | + * @param string[] $where | |
| 218 | 226 | */ | 
| 219 | 227 | public function delete($table, $where) | 
| 220 | 228 |      { | 
| @@ -253,6 +261,9 @@ discard block | ||
| 253 | 261 | return $table; | 
| 254 | 262 | } | 
| 255 | 263 | |
| 264 | + /** | |
| 265 | + * @param string $table | |
| 266 | + */ | |
| 256 | 267 | private function tableExists($table) | 
| 257 | 268 |      { | 
| 258 | 269 | // todo: implement table check |