Skip to content

Commit 4fb0873

Browse files
committed
Fixed a few more infrastructure namespaces
1 parent fdb8565 commit 4fb0873

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

http-basics.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ use Opulence\Ioc\Bootstrappers\Bootstrapper;
4343
use Opulence\Ioc\IContainer;
4444
use Opulence\Orm\Repositories\IRepository;
4545
use Project\Application\Http\Controllers\UserList;
46-
use Project\Domain\Users\Orm\UserRepo;
46+
use Project\Domain\Users\UserRepo;
4747

4848
class UserBootstrapper extends Bootstrapper
4949
{

orm-data-mappers.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ All data mappers must implement `Opulence\Orm\DataMappers\IDataMapper`, which in
8080
You'll frequently find yourself wanting to query entities by some criteria besides Id. For example, you might want to look up posts by title using a `getByTitle()` method. Let's create an interface with this method:
8181

8282
```php
83-
namespace Project\Domain\Posts\Orm\DataMappers;
83+
namespace Project\Infrastructure\Posts\DataMappers;
8484

8585
use Opulence\Orm\DataMappers\IDataMapper;
8686

@@ -410,7 +410,7 @@ Our `getByTitle()` method calls `$this->read()`, which automatically handles rea
410410
Instead of just containing the author's name, let's say your `Post` object contains an `Author` object. Whenever you query a `Post` object from the data mapper, you'll also need to query the `Author` object. The easiest way to do this is to inject the author repository into the post data mapper:
411411

412412
```php
413-
use Project\Domain\WordPress\Orm\AuthorRepo;
413+
use Project\Domain\WordPress\AuthorRepo;
414414
use Project\Domain\WordPress\Post;
415415

416416
class PostDataMapper extends SqlDataMapper

orm-repositories.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ As you can see, there is no `save()` method in repositories. To actually save a
9292
use Opulence\Orm\Repositories\Repository;
9393
use Opulence\Orm\UnitOfWork;
9494
use Project\Domain\WordPress\Post;
95-
use Project\Infrastructure\WordPress\Orm\DataMappers\PostSqlDataMapper;
95+
use Project\Infrastructure\WordPress\DataMappers\PostSqlDataMapper;
9696

9797
// Assume $unitOfWork is already instantiated
9898
$repo = new Repository(Post::class, new PostSqlDataMapper(), $unitOfWork);

0 commit comments

Comments
 (0)