mirror of
https://github.com/JanGross/quicknotes.git
synced 2025-12-01 07:37:18 +01:00
Fix some regresions
This commit is contained in:
@@ -94,7 +94,7 @@ class SettingsController extends Controller {
|
||||
|
||||
switch ($type) {
|
||||
case SettingsService::COLOR_FOR_NEW_NOTES_KEY:
|
||||
$value = $this->settingsService->getColorForNewNotes($this->userId);
|
||||
$value = $this->settingsService->getColorForNewNotes();
|
||||
break;
|
||||
default:
|
||||
$status = self::STATE_FALSE;
|
||||
|
||||
@@ -31,6 +31,7 @@ use OCP\IRequest;
|
||||
use OCA\QuickNotes\Db\NoteShare;
|
||||
use OCA\QuickNotes\Db\NoteShareMapper;
|
||||
|
||||
use OCP\AppFramework\Db\DoesNotExistException;
|
||||
|
||||
class ShareController extends Controller {
|
||||
|
||||
|
||||
@@ -7,7 +7,7 @@ use OCP\AppFramework\Db\Entity;
|
||||
|
||||
/**
|
||||
* @method void setColor(string $color)
|
||||
* @method strinf getColor()
|
||||
* @method string getColor()
|
||||
*/
|
||||
class Color extends Entity implements JsonSerializable {
|
||||
|
||||
|
||||
@@ -30,7 +30,7 @@ class ColorMapper extends QBMapper {
|
||||
$qb->select('*')
|
||||
->from($this->tableName)
|
||||
->where(
|
||||
$qb->expr()->eq('color', $qb->createNamedParameter($color, IQueryBuilder::PARAM_STRING))
|
||||
$qb->expr()->eq('color', $qb->createNamedParameter($color, IQueryBuilder::PARAM_STR))
|
||||
);
|
||||
return $this->findEntity($qb);
|
||||
}
|
||||
|
||||
@@ -43,6 +43,7 @@ use OCA\QuickNotes\Db\TagMapper;
|
||||
use OCA\QuickNotes\Service\FileService;
|
||||
use OCA\QuickNotes\Service\SettingsService;
|
||||
|
||||
use OCP\AppFramework\Db\DoesNotExistException;
|
||||
|
||||
class NoteService {
|
||||
|
||||
@@ -408,7 +409,7 @@ class NoteService {
|
||||
// Get Note and Color
|
||||
try {
|
||||
$note = $this->notemapper->find($id, $userId);
|
||||
} catch(Exception $e) {
|
||||
} catch(DoesNotExistException $e) {
|
||||
return;
|
||||
}
|
||||
$oldcolorid = $note->getColorId();
|
||||
|
||||
Reference in New Issue
Block a user