Commit graph

2797 commits

Author SHA1 Message Date
Hypolite Petovan edc49ec9b4 Add expected "users" property to NodeInfo usage property for all versions 2022-07-23 13:21:44 -04:00
Roland Häder cf8698afe6
This is the correct way:
<?php
if (!isset($foo['account_removed) || $foo['account_removed'])
?>
2022-07-19 18:08:18 +02:00
Roland Häder cb2a052a70
Fixed E_NOTICE, for some strange reason 'account_removed' isn't around? 2022-07-18 23:49:58 +02:00
Michael af8e059990 Renamed platform definition file 2022-07-18 03:48:19 +00:00
Michael 46fdd9893c Merge remote-tracking branch 'upstream/develop' into server-detection 2022-07-17 15:42:09 +00:00
Michael 2ddf37f32d Emergency fixes to fix a bunch of fatal errors 2022-07-17 11:47:12 +00:00
Michael d52f52f45f Somed added documentation 2022-07-17 05:42:44 +00:00
Michael 0a19759e4f Fix wrong variable type 2022-07-16 13:44:35 +00:00
Michael 8b7cb5d9ef Merge remote-tracking branch 'upstream/develop' into server-detection 2022-07-16 12:44:21 +00:00
Michael 896fd3fc91 Use the redirect value 2022-07-14 05:39:25 +00:00
Philipp Holzer d74e57ef2c
include suggested changes 2022-07-13 00:23:12 +02:00
Philipp Holzer a910fd8864
Split DBStructure & View to avoid DB-calls and dependencies for basic operations
- new "Definition" classes vor DB and Views
- new "Writer" classes to create SQL definitions for DB and Views
- DBStructure & View are responsible to execute DB-querys
2022-07-12 23:40:31 +02:00
Michael dad05f1c76 Only fetch the first word for the platform 2022-07-10 13:52:38 +00:00
Michael 85c7bacb00 Improved server detection 2022-07-10 13:01:47 +00:00
Hypolite Petovan eb8237dd89 Remove unused uid parameter in Item::newURI 2022-07-09 07:39:51 -04:00
Michael cc75eb5d18 Improved server detection 2022-07-05 05:04:05 +00:00
Roland Häder a392a22eee
Changes:
- added some type-hints
- fixed some documentation (void is lately returned, not null)
- added some documentation
2022-06-27 15:16:17 +02:00
Roland Häder 98bc5216ef
A bit more documentation 2022-06-27 15:16:17 +02:00
Roland Häder 8e19998191
Fixes:
- more "bool expected but null returned" errors
2022-06-27 13:49:53 +02:00
Roland Häder 7c049abfda
Fixed:
- Contact/User::isBlocked() needs to return boolean, but sometimes (strangely)
  a NULL can come from database, so let's cast it

This tries to fix:
TypeError: "Return value of Friendica\Model\Contact\User::isBlocked() must be of the type bool, null returned"
2022-06-27 11:39:18 +02:00
Philipp e594656a48
Merge pull request #11684 from MrPetovan/bug/11651-ap-fetch-queue
Create ActivityPub\FetchQueue and ActivityPub\FetchQueueItem classes
2022-06-26 13:36:19 +02:00
Philipp Holzer 0223c030a9
Improve 2 factor usage 2022-06-25 23:04:00 +02:00
Hypolite Petovan da32fa8fa6 Create ActivityPub\FetchQueue and ActivityPub\FetchQueueItem classes
- These classes are used to flatten the recursive missing activity fetch that can hit PHP's maximum function nesting limit
- The original caller is responsible for processing the remaining queue once the original activity has been fetched
2022-06-25 12:40:54 -04:00
Hypolite Petovan 3c70d592f6
Merge pull request #11689 from Quix0r/rewrites/double-quotes-single
Changed more double-quotes to single
2022-06-25 12:02:01 -04:00
Hypolite Petovan a7d49877a8 Centralize share tag attribute extraction code in Content\Text\BBCode 2022-06-25 11:46:52 -04:00
Roland Häder 88870d18be
Changes:
- added some type-hints
- added documentation
2022-06-25 16:48:36 +02:00
Roland Häder 39675fe683
Space for the rescue. ;-) 2022-06-25 16:48:35 +02:00
Roland Häder f12cc9648e
Changes:
- added some type-hints
- changed some double-quotes to single
2022-06-25 16:48:35 +02:00
Hypolite Petovan aa133b5437 Add explicit gserver.site_name string truncate in Model\GServer
- Avoids "Data too long for column 'site_name'" database errors
2022-06-25 06:25:48 -04:00
Hypolite Petovan 636b84b41c Update return value type-hint of GServer::getProtocol
- Address https://github.com/friendica/friendica/issues/11630#issuecomment-1164880874
2022-06-25 05:06:22 -04:00
Hypolite Petovan c5b46fe748
Merge pull request #11681 from Quix0r/fixes/item-guidfromuri-allow-null
Allowing Item::getFromUri()'s 2nd parameter a null value
2022-06-24 10:15:26 -04:00
Roland Häder 82bb36e13d
Changes:
- Made Item::guidFromUri()'s $host parameter optional (allowing null)
- added some type-hints
- added documentation
- this may fix reported issue in #11630
2022-06-24 03:17:57 +02:00
Philipp Holzer d441b90bda
Respect Forwarded-For headers 2022-06-23 22:42:35 +02:00
Roland Häder 202857ba7d
No need to log $tid here 2022-06-23 17:30:17 +02:00
Roland Häder fd8f4269ff
Reformatted code 2022-06-23 17:30:17 +02:00
Roland Häder 182c3db9b8
Changes:
- added type-hints
- added missing documentation
2022-06-23 17:30:15 +02:00
Roland Häder b8353a6eb7
Changes:
- reformatted some array
- added missing documentation
- added type-hints
- changed double-quotes to single
2022-06-23 17:30:14 +02:00
Roland Häder c6c936a80f
Added more type-hints 2022-06-23 17:30:14 +02:00
Roland Häder 2f3705f471
Continued:
- renamed varibales to $camelCase
- added type-hints
- updated documentation
2022-06-23 17:30:11 +02:00
Roland Häder 7eefb9aed8
Changed:
- empty() is maybe superflous here, still I would prefer a code style that is
  written explicitly and not rely on "magic casting"
2022-06-22 18:57:01 +02:00
Roland Häder 101cd2dd10
Changes:
- added some documentation
- fixed some documentation
- changed more double-quotes to singl
2022-06-22 16:14:14 +02:00
Roland Häder ee8d0ad619
Changes:
- added more type-hints
- added some documentation
2022-06-22 14:36:47 +02:00
Tobias Diekershoff 4650ff53d9
Merge pull request #11662 from MrPetovan/bug/11661-splitattachment-null
Ensure parameter 4 of Post\Media::splitAttachment is a boolean value
2022-06-21 06:48:52 +02:00
Roland Häder 752953e472
Changes:
- as @MrPetovan pointed out, $actor can be NULL earlier and used later as NULL
- added some missing type-hints
- added missing documentation
- the added @TODO points out to avoid true|false|null for a boolean
2022-06-20 21:00:19 +02:00
Hypolite Petovan 88eacbf66e Ensure parameter 4 of Post\Media::splitAttachment is a boolean value 2022-06-20 14:34:02 -04:00
Roland Häder 4fb03cf163
Changes:
- fixed a null value handled over to Friendica\Model\APContact::getByURL()
- added missing type-hints
2022-06-20 19:05:02 +02:00
Roland Häder e96a548286
Changes:
- dumped default value for $input
- added unknown 'platform' which prevents an "Undefined index: platform in
  /var/www/.../src/Model/GServer.php on line 940" error
2022-06-20 18:56:22 +02:00
Roland Häder c0d7f8944d
Some calls saved 2022-06-19 11:26:10 +02:00
Roland Häder 2c5685c89c
Changes:
- changed to proper "use Foo\Bar;"
- added doctag
- added return type as this is fixed
2022-06-19 01:11:30 +02:00
Roland Häder 39f2d197ea
Changed to suggestings (back to original) + fixed typo in scalar type 2022-06-18 23:30:37 +02:00